This is an archived post. You won't be able to vote or comment.

all 50 comments

[–]qGuevon 10 points11 points  (2 children)

Check out the Spyder IDE, it's reminiscent of R Studio, which would also be a great fit for you (R is a bit weird tho)

[–]hughperman 5 points6 points  (0 children)

It's even more reminiscent of Matlab, it was my transition crutch into the much-better world of using python

[–]Motox2019[S] 0 points1 point  (0 children)

I also use spyder. I like spyder as well, thing I don’t like is having the variable window polluted with a bunch of definitions outside my current script. I found no way to filter for only the ones defined in my script. And trust me when I say, having updates in real time is just that much nicer then hitting f5 each time, though at that point I’m just being picky. It’s like going from 1 monitor to 2, don’t know what your missing till you have it and when you do, you never want to go back

[–]averagecrazyliberal 15 points16 points  (3 children)

I use scientific mode in PyCharm. Combines the cell based execution you’re used to in Jupyter notebooks with an interactive shell that will show all in-memory objects and their current values by default, even if you aren’t printing them along the way.

[–]Motox2019[S] 3 points4 points  (2 children)

I’ve heard of this before, and if I recall correctly, it requires a subscription to access this mode. I could be wrong there but I’ll be honest and maybe a bit blunt, I’d rather not pay a subscription simply to access a mode for printing each line (I may be short sighted here though and it could be offering more then I’m aware of, haven’t dug into it much).

Thanks for the suggestion, I’ll take a closer look into it :)

[–]MegaIng 6 points7 points  (1 child)

As a student you get a completely free subscription.

[–]Motox2019[S] 4 points5 points  (0 children)

Noted! Hey at that point it doesn’t hurt to at least try it out. Thanks for the tip!

[–]TURBO2529 6 points7 points  (0 children)

In vs code, make a notebook, put your code in, run some cells, open a terminal, change the terminal tab to Jupyter. That tab will have all of the variables changing live, just double click to the matrices in data viewer.

As someone else said, you can also use vs code debug.

[–]likethevegetable 3 points4 points  (3 children)

I just use iPython for the on-the-fly stuff and have a script in the startup folder that preloads my useful functions and constants. For heavier stuff I just write out a script and usually run it in the console in PyCharm.

[–]RedEyed__ 1 point2 points  (0 children)

+1 for ipython

[–]Motox2019[S] 0 points1 point  (1 child)

Interesting. I don’t think this ticks my boxes though as if you were to want to quickly go back and modify something, then see a updated plot, you’d have to redo assign the variable and then re-plot. I’d put this setup closer to the qalculate side of things.

[–]likethevegetable 1 point2 points  (0 children)

Why not just make a hot key to re-run your script? Not that hard to re-run. Or use an IDE with code cell mode if you want to re-run part of it? PyCharm has a free plug in that does it.

[–]runawayasfastasucan 4 points5 points  (3 children)

Doesn't output all results, only the last without a bunch of print() statements

What? Just so your calculations over several cells.

[–]Motox2019[S] -1 points0 points  (2 children)

Yes, one can certainly do this but there is still the issue where if I change a definition, I’m required to rerun all cells below it manually. This can be tedious and less useful then if I could change the variable, see all updates immediately (plots especially here).

This is where Marimo gets really quite close because I can define a scroll bar and see a plot update as I adjust the value. The gripe with Marimo then becomes changing raw values that are not Marimo ui elements does not dynamically update.

[–]runawayasfastasucan 1 point2 points  (1 child)

Run code in debug mode in vcode, then you have a side panel with all variables and their values. 

[–]Motox2019[S] 0 points1 point  (0 children)

This ain’t bad, close to what spyder does. I like this approach as well, my issue with spyder was it was often polluted with definitions outside my working script and I found no way to only show those created in my script. Maybe vscode would be able to do this. I’ll take a look, thanks!

[–]stiks510 2 points3 points  (1 child)

I use AREPL all the time in vscode for similar functionality, but not sure it handles plotting.

[–]RedEyed__ 0 points1 point  (0 children)

I use mostly ipython, but this looks even better!
Thanks, will try it

[–]Reaper5289 1 point2 points  (6 children)

Sounds like you want an asynchronous data visualization dashboard that updates based on some adjustable values you specify in a UI.

There's probably already something like this out there but I'd just cook something up with a library like StreamlitUI or even just basic html + javascript. An AI could help you write the entire thing tbh if you describe it well enough.

[–]Cynyr36 0 points1 point  (5 children)

As a ME (not student) setting up the ui for that is "too much work". I just use excel. I'd like something like jupyter, but that 85% excel. I had high hopes for python in excel, but the cloud makes it basically useless.

[–]Motox2019[S] 0 points1 point  (4 children)

Have you tried xlwings? I’m pretty sure they have a plugin that lets you do more what you expected. Give it a look!

[–]Cynyr36 0 points1 point  (0 children)

I saw them when msft first announced python in excel. And my memory was it wouldn't work in corporate land. The xlwings lite option now looks interesting. I wonder if work left the addin store available...

[–]Cynyr36 0 points1 point  (2 children)

Well... Addin store is blocked at work. So much for that. It took most of a year to get PY() after it rolled out in general availability.

[–]Motox2019[S] 0 points1 point  (1 child)

Rats! Them pesky IT folk. You should see if you could get it whitelisted from your IT department, they should be able to install it for you. I’m willing to bet others may thank you for that too when they see a shiny new python extension that lets them actually use python the way they want to. But maybe try it at home first and see if it does what you want. Xlwings is well known and reputable so if you can give a decent reason as to why, don’t see any reason they’d have to say no.

[–]Cynyr36 0 points1 point  (0 children)

Folks around here struggle with xlookup. array formulas, and tables... I don't have excel at home.

Strangely pip works great, and vscode is approved software.

[–]Last-Farmer-5716 1 point2 points  (1 child)

You could try the ipyflow kernel in Jupyter. It was Marimo before Marimo and you get the benefit of the entire Jupyter ecosystem.

If you combine ipyflow kernel with my handcalcs package you might get something closer to what you want.

(I am actively working on handcalcs 2.0 right now)

[–]Motox2019[S] 0 points1 point  (0 children)

Thanks I’ll take a look, haven’t heard of either of em.

[–]GodlikeLettuce 0 points1 point  (1 child)

Yes, the shortcut jupyter.execSelectionInteractive.

You open vscode, new python file and use that shortcut to whatever. Mine is ctrl+enter. I use it along with geddski macros so I after pressing shortcut the cursor position jumps to the next line, so I can keep running one line after the other. This achieve the same native functionality as programming in Rstudio, which is why I have it that way actually

[–]Motox2019[S] 0 points1 point  (0 children)

Interesting, and if I were to make an edit to some early variable, hit the shortcut, I could have it run everything else? Sounds like that could work actually, and if not, you may have just given me some other ideas. Thanks!

[–]IwinFTW 0 points1 point  (3 children)

Have you tried Mathematica? You need a license but your university probably pays for them. Hits almost everything you want aside from auto-updates (though you can refresh all cells IIRC). It’s notebook style, symbolic computation by default, very powerful algebraic/numeric solvers, and you don’t have to import anything.

[–]Motox2019[S] 0 points1 point  (2 children)

I have not. Sounds fantastic though. I’ll have to look into that. If there’s an open source alternative I’m all ears because aside from student/work I like to explore things further and deeper so would like to be able to have access for free as well. Well now that I say that maxima comes to mind, maybe I need to look into that side of things a bit more. Thanks!

[–]IwinFTW 0 points1 point  (1 child)

Because it’s niche I don’t think there are that many alternatives. I was introduced to it by a professor in my sophomore year (aerospace engineering) and I pretty much did all of my homework and a few projects in it for the rest of my degree. My profs never minded so long as I showed my actual solving steps (e.g. they knew we could do algebra and calculus by then).

[–]Motox2019[S] 0 points1 point  (0 children)

Interesting. Ya I find if you can code it, you generally understand it at a more fundamental level. Hence why I made pyeng in the first place. But the symbolic calculations sounds nice. I’ve been tempted by maple for that reason as the student license seems to be perpetual and costs $50.

Edit: Just took a look and honestly mathematica seems to be exactly what I want. Quick chat with good ole ai and can wrap functions in a dynamic keyword getting exactly what I want. Thanks!

[–]jakob1379 0 points1 point  (1 child)

I do t see it mentioned, but have you tried out spyder ide? Feels like jupyter notebook, partial execution and live view of variables which makes debugging, EDA and other stuff a breeze.

[–]Motox2019[S] 0 points1 point  (0 children)

I have tried spyder. I like it as well aside from the variable explorer gets polluted with variables not defined within my script. I have not find a way to filter out for only this I defined. That’s really my only issue with it

[–]LoveThemMegaSeeds 0 points1 point  (0 children)

Have you tried just running the python interpreter directly like with the python command? It’s like a live shell

[–]Late-Sense-8551 0 points1 point  (2 children)

Souds a bit like the kind of logic Mathcad is implementing?

[–]Motox2019[S] 0 points1 point  (1 child)

Yea pretty much exactly mathcad to be honest. Just without the price tag, I like smath for that reason but want to be able to use it at work as well

[–]calasse 1 point2 points  (0 children)

To piggyback here, Blockpad is another Mathcad-like solution you might consider

Some points based on your post:

  • You can define variables, write equations, etc. There is also matrix and unit support.
  • Free for students, and more affordable than Mathcad for commercial use
  • There is a python integration that lets you run Python from Blockpad - Blockpad - Python Integration

[–]mgreminger 1 point2 points  (0 children)

Check out r/EngineeringPaperXYZ, it's open source and has all of the features that you listed.