• Post Reply Bookmark Topic Watch Topic
  • New Topic

Replacing Google Sheets as a calculation  RSS feed

 
Ranch Hand
Posts: 58
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I would like to write a class that replaces google sheets as a calculation engine.
Presently formulas and data sre passed to google sheets via API and the result returned also via API.
I would like to do all the calculations in java code in an attempt to speed up execution.

Is there a way to avoid calculating every cell sequentially which would probable be too slow.

 
Sheriff
Posts: 22958
43
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Steven Greenbaum wrote:I would like to write a class that replaces google sheets as a calculation engine.
Presently formulas and data sre passed to google sheets via API and the result returned also via API.
I would like to do all the calculations in java code in an attempt to speed up execution.



Why do you think that would speed up execution?

Is there a way to avoid calculating every cell sequentially which would probable be too slow.



Why do you think that would be too slow?

Here's what I think you might consider doing. First, write some code which replaces the Google Sheets calls by Java. For this step, don't try to write code which you think might optimize problems you think you might have. Just write ordinary code. Then see if it's actually faster than the original. (I'm assuming that the Google Sheets code is actually too slow... if it isn't, then performance isn't a reason to dump it. There might be other reasons, though, but you didn't mention any.)

If you now have code which is much slower than Google Sheets, then I'd suggest scrapping the project. Leave it the way it is. If it's faster than Sheets, and fast enough for your requirements, then go with it.

But if you're in the middle range where your code might be usable if it could be a bit faster, that's the time to optimize it. But optimizing doesn't consist of guessing at reasons why it might be slow and trying to fix them; it consists of finding parts where the code uses most of the resource you want to optimize -- in this case, run time -- and then finding ways to change those parts to improve them.
 
Saloon Keeper
Posts: 4090
98
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There's a Java spreadsheet component called Jeppers on SourceForge. That might do the trick if you want a Java GUI.
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!