How to use a python command in Windows?

Asked

Viewed 57 times

0

I made a Python code that takes an excel spreadsheet with data from all over Brazil and creates several files separated by states. Ex: spreadsheet contains data from SP, RJ, BH, RS and etc...

Python takes this parent spreadsheet and separates all states, creating a separate file for each state with its respective acronym. Ex: RJ Spreadsheet, SP Spreadsheet, BH Spreadsheet and etc.

So far blz. Except it’s on the colab. Since it is something of the company, I wanted to do this inside the company PC and I installed python and IDLE but I do not know how to run this code inside the IDLE.

In colab we import pandas among other libraries. Someone can help me to do this using the company PC that contains python and IDLE?

Note: I did not put the code because the code meets me. My problem is to put this to run in python and idle.

1 answer

0

Just to understand..

I saw what you did in the colab I wonder if your python code would be a notebook, the file is like ipynb?

If it is a notebook file, it will be necessary that you have an environment to meet it. It is usually used the Jupyter, you can lower it so independent, configure it by vscode or download the data science tool Anaconda, where will contain the tool.

Jupyter will make the same paper as the colab only locally in your machine, remembering that you will have to make your own Workspace,.

The difference is that in collaboratitory, you’re designing everything by a cloud server from Google itself.

-In this environment you will work the same on colab, import your csv files, import the pandas libraries that were used in your project and run according to your organization in code.

Follow here the links: inserir a descrição da imagem aqui

Installation: https://jupyter.org/install

Documentation: https://jupyter.org/documentation

Optional download via Anaconda: https://www.anaconda.com/products/individual

Example of the Jupyter Project:

inserir a descrição da imagem aqui

Now if it’s just a simple python code. Download it

With python installed on the machine, it is accompanied in a native way a terminal for executions.

It’s very simple, go in your file . py.

  • Right-click > Open with > Select Python cmd.

inserir a descrição da imagem aqui

-After this you will open a console with running your script.

inserir a descrição da imagem aqui

  • Got it. So I already downloaded and installed pycharm and anaconda. I already have the . py file I used in colab. I haven’t touched it yet using the tools I downloaded. As I’m crawling, it still beats a bit of fear. I’m looking for some tutorial to see happen and go doing little by little. Today this parent spreadsheet is on the network and I have to figure out how to run this code whenever I need to update the information. Type create a button with macro vba or some function that opens the file, update and close. If you know how to do and can guide me, I will be grateful.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.