{"id":466,"date":"2010-03-18T14:43:14","date_gmt":"2010-03-18T18:43:14","guid":{"rendered":"http:\/\/www.partofthething.com\/thoughts\/?p=466"},"modified":"2010-03-18T14:43:14","modified_gmt":"2010-03-18T18:43:14","slug":"ipython-on-windows","status":"publish","type":"post","link":"https:\/\/partofthething.com\/thoughts\/ipython-on-windows\/","title":{"rendered":"ipython on windows"},"content":{"rendered":"<p>iPython is a very nice way to fiddle around with Python interactively. Most beginners just use IDLE for this, since it comes with Python. But as you get to plotting stuff, you&#8217;ll find that IDLE just doesn&#8217;t cut it (it freezes every time you plot anything). So you try the regular python command line (on the black screen) but get frustrated that you can&#8217;t change directories or use tabbed completion or anything. You hear about ipython and try to use it but it&#8217;s not very obvious. Well all you have to do is make a shortcut and you&#8217;ll be off and running.By the way, if you had started on Linux in the first place, you wouldn&#8217;t have to deal with all this! Anyway, on Windows,<\/p>\n<p>0. Make sure you have Python installed with matplotlib and numpy modules.<\/p>\n<p>1. Get ipython from<a href=\"http:\/\/ipython.scipy.org\/\"> http:\/\/ipython.scipy.org\/<\/a> install it from the download page for your version of python<\/p>\n<p>2. Make a shortcut to python.exe and then right click it and hit properties to change where it points to to:<\/p>\n<pre>c:python26python.exe \"C:python26scriptsipython\" -pylab<\/pre>\n<p>3. Double click the shortcut.<\/p>\n<p>Yay. Now you have ipython on windows with matplotlib interactive capabilities! I suggest having your text editor open in one window and this ipython window in the other. Edit your code, save it, and then type &#8220;run mycode.py&#8221; to run it in the interpreter.<\/p>\n<figure id=\"attachment_467\" aria-describedby=\"caption-attachment-467\" style=\"width: 272px\" class=\"wp-caption aligncenter\"><a href=\"http:\/\/www.partofthething.com\/thoughts\/wp-content\/uploads\/2010\/03\/pylab.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-medium wp-image-467 \" title=\"pylab screenshot\" src=\"http:\/\/www.partofthething.com\/thoughts\/wp-content\/uploads\/2010\/03\/pylab-272x300.png\" alt=\"\" width=\"272\" height=\"300\" \/><\/a><figcaption id=\"caption-attachment-467\" class=\"wp-caption-text\">A nice screenshot of an interactive matplotlib session on Windows<\/figcaption><\/figure>\n<p>Anyway.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>iPython is a very nice way to fiddle around with Python interactively. Most beginners just use IDLE for this, since it comes with Python. But as you get to plotting stuff, you&#8217;ll find that IDLE just doesn&#8217;t cut it (it freezes every time you plot anything). So you try the regular python command line (on &hellip; <a href=\"https:\/\/partofthething.com\/thoughts\/ipython-on-windows\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">ipython on windows<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"activitypub_content_warning":"","activitypub_content_visibility":"","activitypub_max_image_attachments":4,"activitypub_interaction_policy_quote":"anyone","activitypub_status":"","footnotes":""},"categories":[3],"tags":[51],"class_list":["post-466","post","type-post","status-publish","format-standard","hentry","category-computers","tag-python"],"_links":{"self":[{"href":"https:\/\/partofthething.com\/thoughts\/wp-json\/wp\/v2\/posts\/466","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/partofthething.com\/thoughts\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/partofthething.com\/thoughts\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/partofthething.com\/thoughts\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/partofthething.com\/thoughts\/wp-json\/wp\/v2\/comments?post=466"}],"version-history":[{"count":0,"href":"https:\/\/partofthething.com\/thoughts\/wp-json\/wp\/v2\/posts\/466\/revisions"}],"wp:attachment":[{"href":"https:\/\/partofthething.com\/thoughts\/wp-json\/wp\/v2\/media?parent=466"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/partofthething.com\/thoughts\/wp-json\/wp\/v2\/categories?post=466"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/partofthething.com\/thoughts\/wp-json\/wp\/v2\/tags?post=466"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}