top | item 1884896

Show HN: Spreadsheets using Python - Have you seen this?

97 points| nickpinkston | 15 years ago |pyspread.sourceforge.net | reply

47 comments

order
[+] jaxn|15 years ago|reply
There is also Resolver One. - http://www.resolversystems.com/products/resolver-one/

I have always thought it looked awesome, but is Windows only so I haven't been able to try it.

[+] ivank|15 years ago|reply
I tried Resolver One two years ago and it took 2 minutes to launch. I tried it again right now; first launch took 70 seconds and a subsequent launch took 55 seconds. Also, the interface is quite a bit less responsive than Excel. This might help explain its relative obscurity.
[+] hoffstein|15 years ago|reply
The same guys who created Resolver One recently embarked upon a cloud-based, Python spreadsheet application called Dirigible (http://www.projectdirigible.com/).

It looks pretty cool and improves upon Resolver One (for my purposes) by using pure Python (vs. IronPython) and an EC2 back-end to parallelize calcs. It's also obviously cross-platform.

Disclaimer: I don't work for them, just a happy customer.

[+] grayrest|15 years ago|reply
I did a number of wow theorycrafting spreadsheets (Dorkiest pursuit on Earth!) and found I got more mileage out of the row/column level formulas, named cells, and imports than I did out of the Python integration, which was opposite of what I expected.
[+] 3pt14159|15 years ago|reply
There are a bunch of ways you can use Python in excel for windows (I could never get it to work on the mac version, but I couldn't even get Solver to work on the mac version) One goes through the com the other is a plugin of some kind.

What is truly cool about this one though is that you can leave any python object into a cell. Very cool. Its like programming python in a visual functional language. I suspect that this will be abused. "Yo, look at this slick web app that is run through a spreadsheet".

Edit:

I almost forgot my favorite way to write any code in any language for Excel. Remote User Defined Functions. http://msdn.microsoft.com/en-us/library/ff475859.aspx They are bloody awesome and totally asynchronous in Excel 2010.

[+] nickpinkston|15 years ago|reply
I don't use Excel though - Mac Numbers, OO:Spreadsheets, or gDocs. Sounds sweet though.

I think a "slick web app through a spreadsheet" is a beautiful thing for noobs like me. If "business guys" were able to mock up sites like they make Excel sheets, I think the world of programming would be better off. This is the modern version of full literacy!

Haha - why is Mac Numbers so buggy and lame?!? KeyNote is awesome, but I guess none of the UXers at Apple use spreadsheets... They don't even have freaking trendlines on the charts - for shame.

[+] nickpinkston|15 years ago|reply
I'm a not-very-technical (I can do some coding) co-founder, but I've always been pissed off that Excel doesn't use a normal programming language because I think I'd pickup that language so quickly!

Anyone else interested in something like this? I just stumbled across it and wanted to get people's thoughts.

[+] stoney|15 years ago|reply
Funny you should mention that. I use Excel+Python extensively and have developed my own plugin for embedding Python in Excel. Basically it lets me easily write worksheet functions using Python, and also with some multiprocessing magic lets me calculate them in parallel (which VBA doesn't let you do).

I was debating whether I should clean it up enough to share it (or maybe even sell it!). Seems like there's some interest in this, so maybe I will.

[+] jefffoster|15 years ago|reply
http://common-lisp.net/project/cells/ (Cells) is a data flow language where values are determined by formulas similar to spreadsheets.

So instead of a spreadsheet with a programming language, go the other way around!

[+] ctkrohn|15 years ago|reply
Well, Excel does have VBA. Whether that's a "normal" programming language depends on your definition of "normal." You can do some very useful stuff in it, but you'll feel like you're fighting the language every step of the way.
[+] konad|15 years ago|reply
You can use Excel / Word as a COM object and use any language that does COM.
[+] euroclydon|15 years ago|reply
I used COM and the Python Win32 API to automate Excel, creating reports from data in an MSDE DB. We did this quite extensively at my first job.
[+] skept|15 years ago|reply
For serious data analysis and CSV manipulation work in Python another library to check out is Tabular:

http://www.parsemydata.com/tabular/

It's built on top of Numpy so it's very fast and plays well with the rest of the Numpy/Scipy ecosystem. I've been using it daily for the last couple of weeks on relatively large data sets (>300MB) and have been very pleased with how elegantly and efficiently it handles things like pivot, join and aggregation.

[+] kenneth_reitz|15 years ago|reply
Writing spreadsheets and other tabular data formats for Python is very simple with my Tablib library (http://tablib.org).
[+] nickpinkston|15 years ago|reply
This is pretty sweet. I see it has CSV and Excel export... I'll definitely have to check this out. Thanks for posting / building this!
[+] omaranto|15 years ago|reply
How does it deal with dependencies between cells? How does it figure out what order to update them in?
[+] rflrob|15 years ago|reply
I'd suspect that there's a listing somewhere that says, for a given cell, what other cells depend on it, so it knows to update the others when it's modified. I can't immediately get it to work on my Mac, so I can't test it out, though.

There is a line in the source (_datastructures.py) that generates a KeyError("Circular dependency at %s" % str(key)), so I'd guess that it won't let you do anything that generate cycles on the dependency graph. And once the graph is acyclic, it should be fairly obvious in what order to update things.

[+] gruseom|15 years ago|reply
The standard technique is to keep a directed graph with an edge from a cell to each cell that depends on it, then propagate changes recursively. This works well when the total number of cells isn't large.
[+] tkahnoski|15 years ago|reply
If this could do a basic scatter plot and/or Line graph. I would never need another spreadsheet.
[+] rwl|15 years ago|reply
Looks like the recommended way (according to the tutorial) is to use RPy. I imagine there is some support for pyplot, too, given the Numpy/Scipy integration.
[+] hartror|15 years ago|reply
Spreadsheets with python . . cackles evilly . can you feel the POWER!

In all serious I play with data in CSV format with python all the time so this could be extremely useful especially when I want to automate something spreadsheet related for a client/friend/coworker.

[+] leppie|15 years ago|reply
I wrote one using a LISP dialect a few years back. I still like the idea. :)
[+] epynonymous|15 years ago|reply
this is amazing, what do they use for user interface framework, is it wxpython?