Coder Social home page Coder Social logo

Comments (6)

ellisonbg avatar ellisonbg commented on May 18, 2024 1

from jupyterlab_voyager.

zzhangjii avatar zzhangjii commented on May 18, 2024

Thanks, @ssharif6 , I'll look up into it, maybe the underneath data-frame we extract has a different structure?

from jupyterlab_voyager.

zzhangjii avatar zzhangjii commented on May 18, 2024

Hi, @ssharif6 , it turns out to be an issue about panda dataframe's default setting.
if not specified, pd will only display the first 30 rows + the last 30 rows, so JupyterLab_Voyager will only be able to get this 60 rows of data instead of the full dataset (that's why you see a difference).

Without major changes, to extract the whole dataset from this 'partial' table is almost impossible. So, an easy solution would be just changing the panda settings:

pd.set_option('display.max_columns', None)
pd.set_option('display.max_rows', None)

In this way, the whole frame is displayed, and 'Open Table in Voyager' will get the correct data.

from jupyterlab_voyager.

dhirschfeld avatar dhirschfeld commented on May 18, 2024

Is Open Table in Voyager just scraping the HTML output table? If so, I don't think that's an appropriate method to get the underlying data.

You can't simply change the display of the output because printing large DataFrames will then effectively hang your kernel session.

from jupyterlab_voyager.

zzhangjii avatar zzhangjii commented on May 18, 2024

True, that's definitely not a good solution. But currently Jupyter notebook doesn't expose the source dataset in cell output, for this extension, we don't have an easy way to directly find and access the data unless we modify the notebook itself to add some APIs.

from jupyterlab_voyager.

dhirschfeld avatar dhirschfeld commented on May 18, 2024

^^^ I think this is a general design question that Jupyter needs to answer properly.

I guess a big aspect of this is how you communicate the data from Python/R/whatever objects to the frontend in javascript and had thought arrow might fit the bill there.

IMHO It would be great if the Open in Voyager context menu could be integrated with the variable inspector. They're already doing something similar by providing a phosphor datagrid view for numpy arrays. Although it's not yet an officially supported extension I think it would make sense for it to be in future - it's one of the highest request items from my users.

from jupyterlab_voyager.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.