Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Does any Python IDE let you run a selection of code like R does? [closed]

Tags:

python

ide

I think this is a very useful feature for beginners. When I learned R, I would keep my notes for each lesson in one file and execute the lines that I wanted. Now I'm learning Python, and I have to save each new thing in a different file. Is there no IDE that can do what R does? I'm currently using PyCharm.

like image 349
Patrick Yan Avatar asked Feb 06 '13 01:02

Patrick Yan


People also ask

Is there something like R Studio for Python?

The RStudio IDE(opens in a new tab) is a free and open-source IDE for Python, as well as R. You can write scripts, import modules, and interactively use Python within the RStudio IDE. To get started writing Python in the RStudio IDE, go to File, New File, then Python Script.

How do I keep a Python program running forever?

Challenge: Run a piece of Python code forever—until it is forcefully interrupted by the user. Solution: use a while loop with a Boolean expression that always evaluates to True . Examples: have a look at the following variants of an infinite while loop.


1 Answers

In PyCharm, select a code fragment you want to execute then choose "Execute selection in console" (Alt+Shift+E in my keymap).

like image 144
Andrey Vlasovskikh Avatar answered Nov 07 '22 05:11

Andrey Vlasovskikh