{"id":528,"date":"2023-02-24T03:40:46","date_gmt":"2023-02-24T08:40:46","guid":{"rendered":"https:\/\/moodle.sit.ac.in\/blog\/?p=528"},"modified":"2023-07-09T13:30:19","modified_gmt":"2023-07-09T08:00:19","slug":"setting-up-anaconda-python-programming-environment","status":"publish","type":"post","link":"https:\/\/moodle.sit.ac.in\/blog\/setting-up-anaconda-python-programming-environment\/","title":{"rendered":"Setting up Anaconda Python Programming Environment on Ubuntu"},"content":{"rendered":"\n<p>This tutorial will help you in setting up a Anaconda Python 3 programming environment on Ubuntu 22.04. (Should also work on previous release Ubuntu 20.04 as well). If you do not have Ubuntu 22.04 installed on your machine, you can follow the detailed description of installing Ubuntu 22.04 Desktop in the following link below. <br><a href=\"https:\/\/ubuntu.com\/tutorials\/install-ubuntu-desktop#1-overview\" target=\"_blank\" rel=\"noopener\" title=\"\">https:\/\/ubuntu.com\/tutorials\/install-ubuntu-desktop#1-overview<\/a><\/p>\n\n\n\n<p>Majority of GNU\/Linux distribution including Ubuntu 22.04 and other versions of Debian Linux ship with Python 3 pre-installed. You can check whether Python is installed or not by issuing the following command in the terminal. To launch the terminal press <strong>Ctrl+Alt+t<\/strong><\/p>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#2e3440ff\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"$ python3 -V\" style=\"color:#d8dee9ff;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki nord\" style=\"background-color: #2e3440ff\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #D8DEE9\">$<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #D8DEE9\">python3<\/span><span style=\"color: #D8DEE9FF\"> <\/span><span style=\"color: #81A1C1\">-<\/span><span style=\"color: #D8DEE9\">V<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<p>You\u2019ll receive output in the terminal window that will let you know the version number. While this number may vary, the output will be similar to this:<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-full is-resized\"><a href=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda00.png?ssl=1\"><img data-recalc-dims=\"1\" decoding=\"async\" data-src=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda00.png?resize=599%2C189&#038;ssl=1\" alt=\"\" class=\"wp-image-529 lazyload\" width=\"599\" height=\"189\" data-srcset=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda00.png?w=666&amp;ssl=1 666w, https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda00.png?resize=300%2C95&amp;ssl=1 300w\" data-sizes=\"(max-width: 599px) 100vw, 599px\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" style=\"--smush-placeholder-width: 599px; --smush-placeholder-aspect-ratio: 599\/189;\" \/><\/a><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Anaconda Distribution<\/h2>\n\n\n\n<p>Anaconda Distribution equips individuals to easily search and install thousands of Python\/R packages and access a vast library of community content and support. Especially with Python being very popular and de-facto platform for Data Science. Also it provides good graphical IDEs like <strong>Spyder<\/strong> and <strong>Jupyter Notebook<\/strong>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Download Anaconda Distribution<\/h2>\n\n\n\n<p>If you want to install Anaconda Distribution on your system, you can download it from its official webpage. https:\/\/www.anaconda.com\/products\/distribution .It is available for Linux, Mac, Windows platforms. Download the suitable version based on your operating system.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda01.png?ssl=1\"><img data-recalc-dims=\"1\" decoding=\"async\" width=\"1024\" height=\"552\" data-src=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda01.png?resize=1024%2C552&#038;ssl=1\" alt=\"\" class=\"wp-image-530 lazyload\" data-srcset=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda01.png?resize=1024%2C552&amp;ssl=1 1024w, https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda01.png?resize=300%2C162&amp;ssl=1 300w, https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda01.png?resize=768%2C414&amp;ssl=1 768w, https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda01.png?w=1366&amp;ssl=1 1366w\" data-sizes=\"(max-width: 1000px) 100vw, 1000px\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" style=\"--smush-placeholder-width: 1024px; --smush-placeholder-aspect-ratio: 1024\/552;\" \/><\/a><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Install Anaconda Distribution<\/h2>\n\n\n\n<p>Headover to the folder where it is was downloaded. Open a terminal and navigate to the folder. Run the 3 commands as shown in the diagram below.<\/p>\n\n\n\n<p><\/p>\n\n\n\n<figure class=\"wp-block-image size-full is-resized\"><a href=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda02.png?ssl=1\"><img data-recalc-dims=\"1\" decoding=\"async\" data-src=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda02.png?resize=666%2C210&#038;ssl=1\" alt=\"\" class=\"wp-image-531 lazyload\" width=\"666\" height=\"210\" data-srcset=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda02.png?w=666&amp;ssl=1 666w, https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda02.png?resize=300%2C95&amp;ssl=1 300w\" data-sizes=\"(max-width: 666px) 100vw, 666px\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" style=\"--smush-placeholder-width: 666px; --smush-placeholder-aspect-ratio: 666\/210;\" \/><\/a><\/figure>\n\n\n\n<p>The installer proceeds to setup the Anaconda distribution. Choose to perform the default action yes whenever prompted.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Launch Anaconda Distribution<\/h2>\n\n\n\n<p>Once installed open a terminal and run the following command to launch Anaconda Navigator.<\/p>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#24292e\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"putta:~$ anaconda-navigator \" style=\"color:#e1e4e8;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki github-dark\" style=\"background-color: #24292e\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #B392F0\">putta<\/span><span style=\"color: #E1E4E8\">:<\/span><span style=\"color: #F97583\">~<\/span><span style=\"color: #E1E4E8\">$ anaconda<\/span><span style=\"color: #F97583\">-<\/span><span style=\"color: #E1E4E8\">navigator <\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<p>Once the Anaconda is up and running as shown below. Next in Anaconda Navigator choose Spyder IDE. Click on the launch button below it to start the IDE.<\/p>\n\n\n\n<p><\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda04.png?ssl=1\"><img data-recalc-dims=\"1\" decoding=\"async\" width=\"1024\" height=\"552\" data-src=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda04.png?resize=1024%2C552&#038;ssl=1\" alt=\"\" class=\"wp-image-532 lazyload\" data-srcset=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda04.png?resize=1024%2C552&amp;ssl=1 1024w, https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda04.png?resize=300%2C162&amp;ssl=1 300w, https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda04.png?resize=768%2C414&amp;ssl=1 768w, https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/anaconda04.png?w=1366&amp;ssl=1 1366w\" data-sizes=\"(max-width: 1000px) 100vw, 1000px\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" style=\"--smush-placeholder-width: 1024px; --smush-placeholder-aspect-ratio: 1024\/552;\" \/><\/a><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Using Spyder IDE<\/h2>\n\n\n\n<p>The Spyder IDE appears as shown below. Type a Python program and save it with .py extension. A sample program is shown below.<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-large is-resized\"><a href=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/Py-2.png?ssl=1\"><img data-recalc-dims=\"1\" decoding=\"async\" data-src=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/Py-2.png?resize=840%2C440&#038;ssl=1\" alt=\"\" class=\"wp-image-535 lazyload\" width=\"840\" height=\"440\" data-srcset=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/Py-2.png?resize=1024%2C537&amp;ssl=1 1024w, https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/Py-2.png?resize=300%2C157&amp;ssl=1 300w, https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/Py-2.png?resize=768%2C402&amp;ssl=1 768w, https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/Py-2.png?w=1044&amp;ssl=1 1044w\" data-sizes=\"(max-width: 840px) 100vw, 840px\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" style=\"--smush-placeholder-width: 840px; --smush-placeholder-aspect-ratio: 840\/440;\" \/><\/a><\/figure>\n\n\n\n<p>Then click on Run button (green triangle button) to execute the program. If the program has any errors they<br>are shown on console on the bottom right section. Otherwise the program starts executing and output is shown in<br>the console sub window. A sample is shown below.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/Py2-1.png?ssl=1\"><img data-recalc-dims=\"1\" decoding=\"async\" width=\"1024\" height=\"537\" data-src=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/Py2-1.png?resize=1024%2C537&#038;ssl=1\" alt=\"\" class=\"wp-image-537 lazyload\" data-srcset=\"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/Py2-1.png?resize=1024%2C537&amp;ssl=1 1024w, https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/Py2-1.png?resize=300%2C157&amp;ssl=1 300w, https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/Py2-1.png?resize=768%2C402&amp;ssl=1 768w, https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/Py2-1.png?w=1044&amp;ssl=1 1044w\" data-sizes=\"(max-width: 1000px) 100vw, 1000px\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" style=\"--smush-placeholder-width: 1024px; --smush-placeholder-aspect-ratio: 1024\/537;\" \/><\/a><\/figure>\n","protected":false},"excerpt":{"rendered":"<p>This tutorial will help you in setting up a Anaconda Python 3 programming environment on Ubuntu 22.04. (Should also work on previous release Ubuntu 20.04 as well). If you do not have Ubuntu 22.04 installed on your machine, you can follow the detailed description of installing Ubuntu 22.04 Desktop in the following link below. https:\/\/ubuntu.com\/tutorials\/install-ubuntu-desktop#1-overview [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":545,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"site-container-style":"default","site-container-layout":"default","site-sidebar-layout":"default","disable-article-header":"default","disable-site-header":"default","disable-site-footer":"default","disable-content-area-spacing":"default","_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[3],"tags":[69,72,40,71,70],"class_list":["post-528","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-programming","tag-anaconda","tag-install","tag-python","tag-setup","tag-ubuntu"],"aioseo_notices":[],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"https:\/\/i0.wp.com\/moodle.sit.ac.in\/blog\/wp-content\/uploads\/2023\/02\/PyLabManual.png?fit=1059%2C350&ssl=1","jetpack-related-posts":[],"jetpack_sharing_enabled":true,"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/moodle.sit.ac.in\/blog\/wp-json\/wp\/v2\/posts\/528","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/moodle.sit.ac.in\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/moodle.sit.ac.in\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/moodle.sit.ac.in\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/moodle.sit.ac.in\/blog\/wp-json\/wp\/v2\/comments?post=528"}],"version-history":[{"count":1,"href":"https:\/\/moodle.sit.ac.in\/blog\/wp-json\/wp\/v2\/posts\/528\/revisions"}],"predecessor-version":[{"id":837,"href":"https:\/\/moodle.sit.ac.in\/blog\/wp-json\/wp\/v2\/posts\/528\/revisions\/837"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/moodle.sit.ac.in\/blog\/wp-json\/wp\/v2\/media\/545"}],"wp:attachment":[{"href":"https:\/\/moodle.sit.ac.in\/blog\/wp-json\/wp\/v2\/media?parent=528"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/moodle.sit.ac.in\/blog\/wp-json\/wp\/v2\/categories?post=528"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/moodle.sit.ac.in\/blog\/wp-json\/wp\/v2\/tags?post=528"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}