I don't know about "better" as I don't have a lot of experience with either—I've only dabbled or used them to prototype something small. The major differentiator is the JS implementation and ability to import libraries from sibling notebooks and other sources.
But yeah I'd have to agree that Bostock is a beast.
Observable does some things quite well for that use case:
-- Easier dependencies: no need for 'npm install', just 'require(...)'
-- URL publishing
-- Collaborative merge flow
However, Jupyter made some good decisions that make it win over Observable for our day-to-day data work:
-- Manual reexecution vs. automatic: when working with big data, outside APIs, etc., Observable's automatic reexecution is a non-starter
-- Fully open source, embeddable, and successful history of non-vc funding: Jupyter is organized and provided in a way companies ( who aren't Amazon ;-)) can rally around, evidenced by contributions by Bloomberg etc.
-- Access to underlying unix/windows env and multiple environments (multiple Python versions, ...). As much as I wish Observable's choice of JS could provide a viable data environment, and I've personally invested in making it so and the path to making it first-class is clear, we need way more gov/google/nvidia/etc. support.
Ultimately, for not-too-sensitive collaborative data work, we use Google Colab, then offline and sensitive commercial work via Jupyter (Graphistry ships with it preloaded for GPU dataframe & GPU visual graph analytics goodness!), and if we did more in JS tutorial land, Observable would be my first choice.
The (reactive JavaScript) Observable runtime is open source, and every notebook is available compiled as an ES Module.
You can embed notebooks in their entirety on any webpage, or just grab the embed code for an individual cell, if the notebook produces a single visualization.
Does that now include the ability to create and edit, or still just run? Having to rely on a third party to create and edit could be problematic for some purposes.
A comment from May last year [1] says "But that won’t include the editable notebook interface or the rest of observablehq.com - unlike Jupyter, we’re really aiming to create a community and cross-pollination of concepts and code rather than individual installations. We might eventually launch something that enables offline editing, but that’s a bit further out in the future."
Even though I love Python I don't really like Jupyter, seems like with a dev environment like VS or VSCode I can't quite find the right use case.
With C# it might be a different story, since the development cycle is fundamentally edit-compile-run an environment like Jupyter might give me an extra platform for in-between testing. I already use the Interactive built into VS quite a bit to figure out, for example, just the right format string for Datetime.Now.ToString() or stuff like that.
The benefit of Jupyter notebooks really is about being able to share chunks of code and write narrative around it.
It isn’t really aiming to replace a dev environment like VSCode.
We’re seeing a rise of notebooks in particular because they encourage writing a lot of plain text around your code, and that’s really good both for teaching, and promoting good documentation skills for learners.
>share chunks of code and write narrative around it.
>encourage writing a lot of plain text around your code
Is this targeted at non techies? Teachers?
Can someone provide some good example of this? Not having used it much trying to understand what the advantages are over good quality documentation/tutorial pages on say msdn.
Jupyter came from the scientific community (originally the IPython Notebook - IPython itself was made by a physics grad student).
The use case is basically a scientific journal. You collect data. Analyze it. Make plots. Write notes (e.g. with equations, or diagrams). All in one place.
Then you can share the notebook with anyone else. If they have similar data (in the same format), they can execute the notebook on their data and get the plots all in one place.
It's great for data oriented work. It was never meant as an IDE replacement, nor as a general purpose development environment.
In a previous job I had set up a notebook to analyze some of the models our team produced - it was essentially a Q/A notebook that generated data from our models, algorithmically looked for unphysicalities in our models, and plotted any it found.
The rest of my team used it for the models they were working on. The alternative/old way was just too painful (lots of manual steps).
But although reuse by others is a touted feature, it's not really that important. It's incredibly useful for one's own workflow. Think of the convoluted Excel sheets people often have at engineering companies. They get new data, copy and paste it into Excel, and get new plots. This is no different.
> Can someone provide some good example of this? Not having used it much trying to understand what the advantages are...
Sure! Here are some ways I use notebooks:
Imagine any scenario in which you'd rather make a video to demonstrate how something works. For a lot of those cases, a notebook is a great way to show how the code works and how it all comes together.
Another set of use cases is you've done some research, need to call a few api's, post process the results, and share that with your team or have it ready for later to do something similar. You could think of this as a "Super Postman". For example, you need to run some api's in a loop, filter the results, and accumulate some things and print totals at the end.
Another use case is you're troubleshooting an issue, and want to keep notes of what you've tried, what the results were, and be ready to go back and run things again.
It solves the problem of scientists that have done experiments, but have no way to share and have their experiments and have them validated using the same procedures and programs. At least that's the way I understand it.
I do financial data analysis and Jupyter Notebooks allows me to run scripts while explaining my findings/arguments about the data within the same space.
It's a convenient way to present both data and narrative to whoever might need to see it.
I also like being able to run snippets when writing scripts, at least when it comes to building/testing. I'm more on the data science side than the dev side though, so that's probably why Jupyter Notebooks appeal to me more than other IDEs.
Try F# feels like Python in most regards but ends up having type inference.
Edit: if you think “oh that’s nice, just like Java/C++”, HECK NO. It goes beyond this, where complex modeling can easily be represented and things like pattern matching and other features not known in other langs
Hello! We're taking a look at improving these kinds of programming scenarios in F# for the next version of the language. Since F# is first-class in the jupyter experience, one of those hurdles is already done!
That said, improvements to the language can only go so far. We're trying to figure out what a good set of libraries for the whole range of ML tasks looks like for F# and .NET.
Continue the good work :) I use mostly C# out of habit but F# is my favorite in terms of expressiveness. I'm planning a series of educational videos in French about the language because it doesn't have the exposure it merits.
I've been out of the scene for a bit but last I looked Miguel had created tensorflow bindings for .Net. With some magic require incantations I was able to get that into F# and it actually worked.. Looks like there is SciSharp now and that project looks like it's heading in the right direction.
The key, IMHO, is going to be getting some influential people and projects on F# generating code and blog content. The user experience of getting setup for them and the audience they reach needs to be streamlined. From there if it JustWorks™ F# should do the rest of the selling :)
And to digress, because I always mention this when talking about F#, it deserves a batteries included web framework story as good as Elixir's Phoenix.
> And to digress, because I always mention this when talking about F#, it deserves a batteries included web framework story as good as Elixir's Phoenix.
I was thinking of writing the bindings to Pytorch directly to C++ for F# now that would be the killer thing to bring on to .net . It’d be like writing As close as writing Python but order of magnitude improvement for performance. But that’s a lot of work and I don’t do much ml work lol so meh Someone should do it
The thing that I find really daunting with Jupyter is the set of APIs that it seems I need to learn in order to get it to do anything cool, like for example visualizing data or a function, or making an interactive widget that does the same. I don’t remember the same kind of pain when playing around with Mathematica. I really want to like it and learn it — I really like interactive programming. It just never makes it high enough on my brain space list to seem worth it.
Since C# is my daily language, this is pretty cool though. I just really wish that I had a use-case strong enough for it to overcome the initial pains of learning it and the ongoing mental maintenance of staying usefully fluent in yet another set of libraries.
Agreed on the bewildering number of disparate APIs that you need to bash together in a Jupyter notebook. Data wrangling, plotting, machine-learning, logging, writing to file/DB... It doesn't help that there are often multiple competing packages that solve basically the same problem in different ways, ensuring that whatever choice you make will be fraught with anxiety about not "doing it right."
That being said, I've found the only way I can get interactive programming to stick in my mind is to pick a sample dataset, wonder some open-ended questions about it, and then answer those questions in a Jupyter notebook with the help of Google, documenting your thought process as you go. A great starting point to find real-world sample data is the UCI dataset repository: https://archive.ics.uci.edu/ml/datasets.php
My use case is algorithm prototyping/development. It lets me mostly put the code aside and concentrate and quickly iterate on the algorithm. It's just a fancy, persistent, reproducible, REPL.
True, but what made the Mono REPL particularly remarkable was that it launched with much of the functionality of a notebook, with things like inline graphics.
> I already use the Interactive built into VS quite a bit to figure out, for example, just the right format string for Datetime.Now.ToString() or stuff like that.
what I end up doing is having both the dev env and jupyter open at the same time - doing dev the normal way and then using a jupyter notebook for q&d manual validation and plots.
like others said already, jupyter isn't a development environment and trying to use it like one is asking for trouble, but it is a great REPL on some awesome steroids.
I love .NET and I love Jupyter. I don't know how well they will combine though. I feel like the lack of Pandas and flexible typing of Python will make it a lot less useful.
It currently works with Deedle and XPlot.Plotly (which I personally far prefer to FSharp.Charting). We're also adding XPlot.GooglePlots support for rendering the charts inline.
Hello. I am the current maintainer of Deedle. Recently, I have been focused on use cases of MathNet interop. Deedle.Math was released last week. pandas-like matrix dot functions are available now. Lots of linear algebra, stats and finance related functions are added too. More finance domain functions and docs improvements are on my to-do list.
I am really excited about the new Data Frame from corefxlab to complement what Deedle lacks. Since Deedle's original core engineering team has left and moved on, some core technical debt are beyond my capability to address. But Deedle is still the best data frame library in .Net ecosystem for now if you are able to get around some of its odd edges.
Hello! Deedle is actively maintained, as is the XPlot library and a few others under the fslaborg organization on GitHub. However, it's not without its flaws and addressing them in the best way possible would be a breaking change. Additionally, the .NET team is working on a core DataFrame API that could service these needs here.
Trying in my limited spare time to learn Scala and use it here and there on the job for script like stuff of our Java sim and simple analysis. I found almond a bit slow in compiling cells and then found BeakerX. Seemed much faster. Have any thoughts between the two (if you've used BeakerX)
This is great news. Jupyter has become my default tool for prototyping code. I keep trying other platforms that should theoretically have the same features, but I just find Jupyter much more pleasant to use.
Not the OP but I enjoyed the "Introduction to F#" notebook there. Interactivity let me see what the error messages are like for eaxmple replacing "negate" with "42" in the pipeline example.
(hint to Jupyter newbies: alt-enter re-evaluates the code block after editing it)
.NET core is open source and has worked on windows, mac os, and linux for a while now. I started working on a front end for a C# .net core project recently which is being developed at a primarily Windows shop and I got it running on Ubuntu in 15 minutes. I would have died before picking a Microsoft stack for a project 5 years ago, but the back end for my next project will be .net core. The developer experience and tooling are second to none these days. You really should give it another look.
Kind of. .NET Framework will be the XP of .NET until Microsoft provides an actual migration path to many of the APIs and frameworks that haven't made it into .NET Core.
Plus some of those APIs that made the cut into .NET Core, like the UI ones, are Windows only.
There are also some critical tooling gaps that mean .Net Core is still broken for scenarios that worked a decade ago (FSI package management with F#, specifically).
Sorry for the loose term. Not package management a la NuGet, but how packages and their references are handled (ie managed), so that they're not available and operative in FSI on .Net Core in VS.
I think the only real drawback is no self hosting.
https://observablehq.com/
A pretty healthy example:
https://observablehq.com/@rreusser/2d-n-body-gravity-with-po...