11 ms·
Hey! This is my project! Amazed to see this here. I'll try to answer questions people might have
by nhatcher 2y ago
Hey! This is my project!
Amazed to see this here.
I'll try to answer questions people might have
- readthenotes1 2y agoWhat keeps me in Excel 2007 is Goal Seek. I'm not sure how unusual I am, but would be interested in knowing:)
- nhatcher 2y agoThanks for the feedback, I will keep this on the back of my head. This and things like sensitivity analysis are not in our immediate roadmap, but this is the kind of thing that would be fairly easy to add. You can do it right now programmatically, of course.
- fatih-erikli-cg 2y agoWhere and how do you handle the operator precedence? I couldn't find in the codebase.
- mdaniel 2y agoI'm cognizant it's just documentation, because the code is its own thing, but it seems to be a recursive descent parser https://github.com/ironcalc/IronCalc/blob/2c2228c2c26386b0197858879eeac195ca39839f/base/src/expressions/parser/mod.rs#L9-L15 https://github.com/ironcalc/IronCalc/blob/2c2228c2c26386b019...
- fatih-erikli-cg 2y ago[flagged]
- bonzini 2y agoThe function for asterisks and slashes is called from the functions for pluses and minuses. The result is that asterisks and slashes are evaluated before pluses and minuses. It's actually very easy to understand once you get the idea. https://en.wikipedia.org/wiki/Recursive_descent_parser https://en.wikipedia.org/wiki/Recursive_descent_parser
- fatih-erikli-cg 2y agoI don't think a recursion should be involved in the parser. Shift-reduce may be an answer but it does not fix the problem either if you try to implement that. I would like to see real code rather than written homework pieces.
- bonzini 2y agoYou're conflating parsing of expressions with operator precedence parsers (aka Pratt parsers). IronCalc uses a recursive descent parser, and Pratt parsers are an optimization of recursive descent parsers. Pratt parsers have one function that implements all precedence levels, while recursive descent parsers have one function per precedence level, but they contain basically the same logic. Source: 20 years ago I converted GCC's C++ parser from recursive descent to an operator precedence parser; obviously GCC respected precedence even before my work, which was purely an optimization. In fact the code I replaced had the note "The expression parser recurses through the various levels of precedence as specified in the grammar, rather than using an operator-precedence technique". https://github.com/gcc-mirror/gcc/commit/b8b94c5ba81744d325f235a0409660f50ac3f361 https://github.com/gcc-mirror/gcc/commit/b8b94c5ba81744d325f...
- fatih-erikli-cg 2y agoOperator precedence is an addition to parsing of expressions. Both of them is needed if you accept "2 + 1" kind of expression. "2 + 2 * 2" must be evaluated like "2 + (2 * 2)". Only expression parsing will evaluate them like 8.
- bonzini 2y agoYou can choose: learn recursive descent parsing, or keep on being confidently incorrect.
- amluto 2y agoBetter not use popular toolchains then: https://gcc.gnu.org/wiki/New_C_Parser https://gcc.gnu.org/wiki/New_C_Parser https://clang.llvm.org/features.html https://clang.llvm.org/features.html I think this is a quite popular approach for multiple reasons. That being said, tree sitter uses GLR.
- nhatcher 2y agoI wrote about it at length here: https://www.nhatcher.com/post/a-rustic-invitation-to-parsing/ https://www.nhatcher.com/post/a-rustic-invitation-to-parsing... The implementation in IronCalc follows that.
- wslh 2y agoThanks for your great work! I’d love to hear your thoughts on a recent “brainstorm” a few of us had here on HN about spreadsheets. How does this resonate with you? [1][2] [1] https://news.ycombinator.com/item?id=42027356 https://news.ycombinator.com/item?id=42027356 [2] https://news.ycombinator.com/item?id=41970554 https://news.ycombinator.com/item?id=41970554
- nhatcher 2y agoHi wsih, thanks! There is a lot to unpack on those threads but of the top of my head: 1. Clear separation between UX/backend Done by design in IronCalc. It is first a spreadsheet engine. 2. Multi language support, language connectivity, enhanced data types, ... You might very well be right, but out first step is to be as close to Excel as possible. We are ~ 1 year away from being formula compatible in a reasonable way. Once we are there we can do better in different directions. I think strict typing might be very beneficial for spreadsheets engines. Anything you can do to reduce errors and human mistakes. I strongly believe that having a competitive spreadsheet engine fully open source might be a good first step in extending and improving Excel. Let's see!
- enugu 2y agoHyperfiddle and Quadratic implement some of the items on your wishlist (richer data types, modern programming languages, working with arrays, better connectivity to data tools).
- echoangle 2y agoWhere does the name come from?
- nhatcher 2y agoThe first well known spreadsheet application was called VisiCalc[0] (the killer app!). The "Iron" side is because it is written in Rust and the domain was available. [0]: https://en.wikipedia.org/wiki/VisiCalc https://en.wikipedia.org/wiki/VisiCalc
- ericra 2y agoGreat project. I particularly love the: 1) mit license 2) using plausible instead of Google analytics. Practically speaking, uBO is going to block both by default, but for non-tech users this is great. 3) appreciate how the app respects your pc when the web app is running in the background. Very low footprint, no random CPU spikes or anything. Wish you guys the best.
- nhatcher 2y agoThanks :). WRT: Plausible. I think I will remove all kinds of analytics, I'm not yet convinced I should be using them at all. That being said I had been longing to try Plausible for the a long time and this seemed like a good opportunity.
- nhatcher 2y agoIf you are curious, I just made the analytics public: https://plausible.io/ironcalc.com https://plausible.io/ironcalc.com I think more than one folk in HN might be interested. All traffic is because of this post. I had no visitors as of today. This was work in progress :)
- twojacobtwo 2y agoSweet, it's basically data on HN users then. Only 13.4% of HN readers use Firefox. For shame. But seriously, it's interesting that safari is top by quite a margin.
- airstrike 2y agoWhere were you when I started writing my code ;_; I have also written a spreadsheet engine in Rust from scratch, for an app built with the iced GUI library! I'll take a deep dive through your repo and compare notes later this week. Congrats on the huge lift!!
- dpe82 2y agoWhat a cool project! I intend to dive in and I'm sure I'll have questions as I do. Are you active in Discord? The invite link on the bottom of ironcalc.com isn't currently valid.
- arjunlol 2y agoLooks cool! What sort of different solutions do you imagine devs building on top of the engine?
- nhatcher 2y agoOne of the recurrent topics is integration with spreadsheets done by non-developers. Imagine a spreadsheet built by the finance department of an institution. It is also maintained by them. The developer team might want to integrate this tool in their workflow. With IronCalc the can add units test or compute it a thousand times, one for each user. I don't think developers would choose IronCalc to do any actual development. They will be forced to by other parts of their tool chain being spreadsheets. Another way would be developers wanting to build spreadsheets with some extensions for a company or organization. Imagine needing a spreadsheet that has a built in SAT solver (like https://github.com/shnarazk/splr https://github.com/shnarazk/splr). That would be easily built in IronCalc. Not sure if any of those ideas convinces you :)
- madjam002 2y agoDo you see this as an alternative to OnlyOffice? I’m wondering if you’ve tried it and how you think this compares
- nhatcher 2y agoI remember trying it out, yes. I yet need to do a serious comparative analysis. For what I can see OnlyOffice is feature complete, it's a full office solution. The sheets component is way ahead from IronCalc. On the plus side, IronCalc is way lighter. When you go to IronCalc you download < 1Mb (compressed), it is faster and able to load larger workbooks on the web. IronCalc is an engine, meaning you don't need a UI at all to run it. I don't think IronCalc is an alternative today to OnlyOffice. At most one day might be an alternative to the sheets component.
- alexk101 2y agoI haven't looked into the source for your project, but am curious if you are integrating any kind of existing engine/backend (Polars is what I am thinking) into it, or if that is even possible.
- nhatcher 2y agoNot as of now. We first want to be a first class spreadsheet engine that implements 90% of Excel functions and features like array functions, LAMBDA, ... A goal of IronCalc is to make things like integrating Polars trivial for a developer.
- hitradostava 2y agoAmazing project. The question I have is why rust? Is the compiled WASM significantly faster than JS?
- nhatcher 2y agoYes, the compiled WASM is significantly faster. Easily by an order of magnitude. I might be completely wrong about this but I _think_ if the brilliant folks at Microsoft research in the calc intelligence group would have waited a few years they might have used wasm instead of TypeScript (https://www.microsoft.com/en-us/garage/wall-of-fame/calc-ts-in-excel-for-the-web/ https://www.microsoft.com/en-us/garage/wall-of-fame/calc-ts-...) As for Rust, could have been C or Zig. I just needed a language that minimally compiles to wasm. There is another reason though. IronCalc runs in the bare metal, not only in the web and needs to have bindings to languages like Python, R or Julia. I can't get that today easily with TypeScript.
- Onavo 2y agoThere might be some tricks from Row Zero that you can borrow https://news.ycombinator.com/item?id=39551064 https://news.ycombinator.com/item?id=39551064 https://news.ycombinator.com/item?id=41512270 https://news.ycombinator.com/item?id=41512270
- yowlingcat 2y agoVery cool library. I like the goal of Excel support (it truly is an incredible platform). A couple of questions: 1) Any plans for programmatic manipulation of pivot tables? Looking across the Python ecosystem, outside of xlwings (which essentially requires FFI manipulation of a running instance of Excel), nothing else makes it possible. It does look like some .NET Excel libraries support it. 2) Will there be ability to use the engine as library? Would love to use something like this through Python bindings.
- nhatcher 2y ago> 1) Any plans for programmatic manipulation of pivot tables? As soon as we possibly can 2) Will there be ability to use the engine as library? Would love to use something like this through Python bindings. That is in place already! It is an MVP, so I haven't published all packages for all architectures but you can compile it from source: https://github.com/ironcalc/IronCalc/tree/main/bindings/python https://github.com/ironcalc/IronCalc/tree/main/bindings/pyth... https://pypi.org/project/ironcalc/ https://pypi.org/project/ironcalc/
- negoutputeng 2y agonice project ! and attempt to modernize the spreadsheet tech stack. be warned though, that the feature-set of the modern spreadsheet is gigantic, with tentacles in hundreds of nooks and corners. Any attempt to play catch-up is a losing proposition. Hence you could position it so as not to directly compete with excel - in areas that are new or emerging. trivia: js based https://ethercalc.net/ https://ethercalc.net/ is in turn is derived from https://github.com/DanBricklin/socialcalc https://github.com/DanBricklin/socialcalc written by the spreadsheet inventor dan bricklin
- fermigier 2y agoFun fact: Audrey Tang, creator of Ethercalc, went on to become Minister for Digital Affairs for the Taiwanese government.
- nhatcher 2y agoI've said this in some other comment. We can't and will never be as feature full as Excel. We want to find different use cases. A super light spreadsheet with MIT license that you can use anyway you want. If I were to go closed source, for instance, I think I loose 90% of my selling points.
- mjrpes 2y agoOne of my dreams if I were to create my own web-based spreadsheet engine would be to make worksheets much more general purpose and not stuck in tab UI like Excel. You would be able to embed them separately in the page so multiple worksheets could be viewed at the same time. Example: you might have multiple small worksheets with financial summaries where the columns are slightly different. You could also do things like include text above/below worksheets, to present the data in a document-like format.
- jitl 2y agoThis is how Apple's Numbers.app works.
- Hashex129542 2y agoNice :) You've added xlsx format to export. Is it legally allowed?
- deleted 2y ago[deleted]
- nhatcher 2y agoYes, it is an open format: https://ecma-international.org/publications-and-standards/standards/ecma-376/ https://ecma-international.org/publications-and-standards/st...
- Hashex129542 2y agoThanks
- eviks 2y agoCool project! Do you have a detailed list tracking compatibility with Excel? Do you have any great ideas where you can surpass it (in one way you can use yours without UI)?
- nhatcher 2y agoThanks! There is not a detailed tracking of all Excel features. But we track: 1. Function implementations: https://github.com/ironcalc/IronCalc/labels/Functions https://github.com/ironcalc/IronCalc/labels/Functions 2. Dynamic arrays, defined names, pivot tables, ... Excel is huge we only aim at implementing a subset.
- eviks 2y agoExactly because Excel is huge it'd be nice to have such a detailed reference, grouped by type: functions, UI, scripting, built in analysis tools etc And some features could reduce pressure re compatibility in other areas. For example, if you had some kind of wasm plugin system, then people could easily write the lacking functions in their favorite language without having to wait for the core to add such a function.
- nhatcher 2y agoThanks for the feedback. I will try to build a more detailed compatibility reference as you describe.
- bsenftner 2y agoHow does your project compare to: https://bossanova.uk/jspreadsheet/v4/ https://bossanova.uk/jspreadsheet/v4/ which is the open source version of https://jspreadsheets.com/ https://jspreadsheets.com/ Serious question. I base a lot of work off the open source jspreadsheet. Curious about yours.
- nhatcher 2y agoAt the moment they are a full production ready product, we only have an MVP. If and when we reach version 1.0 we might be comparable. And you might want to use one or the other. It its difficult to say who the two product will compare in a year from now but probably IronCalc will be lighter, easier to integrate, faster in computations but not so feature full.
- hotbutterscotch 2y agoHey, sorry for the noob question. What is the use case for this. Is it to integrate into webpages for rendering data in spreadsheets/tables ?
- sunshine-o 2y agoBeautiful project. Congrats and thanks !