{"id":2497,"date":"2025-10-22T02:42:29","date_gmt":"2025-10-22T06:42:29","guid":{"rendered":"https:\/\/www.michelecoscia.com\/?page_id=2497"},"modified":"2025-10-22T02:42:42","modified_gmt":"2025-10-22T06:42:42","slug":"disconnect-between-the-public-face-and-the-voting-behavior-of-political-representatives","status":"publish","type":"page","link":"https:\/\/www.michelecoscia.com\/?page_id=2497","title":{"rendered":"Disconnect between the Public Face and the Voting Behavior of Political Representatives"},"content":{"rendered":"\n<p class=\"has-text-align-center wp-block-paragraph\"><strong><a href=\"https:\/\/www.michelecoscia.com\/wp-content\/uploads\/2025\/10\/20251021disconnect.zip\">Download the Code<\/a><\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">This is the data and code necessary to replicate the results in the paper &#8220;<strong>Disconnect between the Public Face and the Voting Behavior of Political Representatives<\/strong>&#8220;.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">We provide both the python script to generate the main results, as well as some Gnuplot scripts to generate the figures.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">All results were generated using Python 3.13.7 and Gnuplot Version 6.0 patchlevel 2. You&#8217;re going to need the following python libraries:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>numpy<\/li>\n\n\n\n<li>scipy<\/li>\n\n\n\n<li>sklearn<\/li>\n\n\n\n<li>pandas<\/li>\n\n\n\n<li>torch<\/li>\n\n\n\n<li>torch_geometric<\/li>\n\n\n\n<li>networkx<\/li>\n\n\n\n<li>umap<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">Simply run the scripts in their numerical order &#8212; scripts require the input from previous scripts, so running them out of order guarantees that errors will be thrown. Note that script 03a generates its own o3b gnuplot script, so if you want to generate that figure you will have to run that additional script. The scripts do not take any parameter, so simply run them as &#8220;python script.py&#8221; or &#8220;gnuplot script.gp&#8221;. Since some methods use randomness, we fixed a given seed for reproducibility: if you do not change the seed number you should get the exact same figures as for the paper (assuming you&#8217;re using the same library versions as we did).<\/p>\n\n\n\n<p class=\"has-text-align-center wp-block-paragraph\"><strong><a href=\"https:\/\/www.michelecoscia.com\/wp-content\/uploads\/2025\/10\/20251021disconnect.zip\">Download the Code<\/a><\/strong><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Download the Code This is the data and code necessary to replicate the results in the paper &#8220;Disconnect between the Public Face and the Voting Behavior of Political Representatives&#8220;. We provide both the python script to generate the main results, as well as some Gnuplot scripts to generate the figures. All results were generated using &hellip; <a href=\"https:\/\/www.michelecoscia.com\/?page_id=2497\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Disconnect between the Public Face and the Voting Behavior of Political Representatives&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"parent":2016,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-2497","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.michelecoscia.com\/index.php?rest_route=\/wp\/v2\/pages\/2497","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.michelecoscia.com\/index.php?rest_route=\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.michelecoscia.com\/index.php?rest_route=\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.michelecoscia.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.michelecoscia.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=2497"}],"version-history":[{"count":2,"href":"https:\/\/www.michelecoscia.com\/index.php?rest_route=\/wp\/v2\/pages\/2497\/revisions"}],"predecessor-version":[{"id":2501,"href":"https:\/\/www.michelecoscia.com\/index.php?rest_route=\/wp\/v2\/pages\/2497\/revisions\/2501"}],"up":[{"embeddable":true,"href":"https:\/\/www.michelecoscia.com\/index.php?rest_route=\/wp\/v2\/pages\/2016"}],"wp:attachment":[{"href":"https:\/\/www.michelecoscia.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=2497"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}