Conversation
|
This is even later, and maybe controversial... |
|
I like the idea in principle, and think it might be useful as well when we implement virtual columns (one could imagine having |
|
@mhvk - I think that makes sense and would simplify the implementation. I do think that I had originally also thought about an API like: I thought about Then Column could have a |
|
@taldcroft - agreed on not re-using format. With your example, I see a bit more why you implemented it as you did. Also, it does seem nice to be able to do |
|
@mhvk - does that mean you would be OK with the original (current) implementation? I looked into putting into Table and the most straightforward method would involve adding a keyword arg to the Table init like |
|
Does this affect the outputted files? (if not, could one end up in a situation where a user gets a table from a code with some columns pre-hidden) and then doesn't understand why the file output doesn't match the printed output? What about the browser-based javascript viewer? |
|
@astrofrog - this affects the HTML output (and thus ipython notebook repr) and browser-based javascript viewer. Basically anything that uses |
|
@taldcroft - how about setting the milestone to 1.0 so as to have more time to discuss this? |
|
@astrofrog - OK milestone is 0.4. |
|
I re-ran the one test that stalled out. |
|
Explicit is better than implicit. I agree with @astrofrog that there is a large potential for confusion. It is very easy already to select a subset of columns, so that the user can easily select which columns should be printed and which should not be printed. Special needs like time columns would be better served by #2790. |
|
Looking back at this, I think that in its current form there is too much potential for confusion (e.g. HTML output vs other formats, etc.). Along the same lines as what @hamogu is suggesting, what about having a method This would be shorthand for except that |
|
The problem with table views as such is that they are not views, but rather copies (as explicitly noted in the example from @astrofrog). So if you want to work with a subset of a table and perform mutable operations, that's a no-go. There is a reason that every spreadsheet app allows the ability to hide columns instead of just make a new sheet with a copy of a subset of columns. I want Table to have spreadsheet-like capabilities (like computed columns), so hiding is a natural feature. |
|
Pushing this to 1.1, but it's still a good idea! 😄 It would be a simple thing to make all columns visible before any I/O operation including pickling. Note that in current master it is now possible to make a quasi-view of a subset of columns: Here As I said, most people have used spreadsheets and everyone agrees it is a good thing to be able to hide/unhide columns on the spreadsheet, and nobody is freaked out because certain data are not visible. |
|
Not 1.1-critical so removing milestone |
|
Looked at this again after a long time (as I was reviewing "ready-for-final-review" PRs), and ended up uncomfortable. Mostly, I feel the state should not be on a Anyway, for now removed the |
|
@mhvk - I look at this PR (longingly) every so often. One thing that has changed in the meantime is moving toward encapsulating new column information in The other problem with having But anyway, if I ever revive this it will be totally different. I would like to leave this open for a little longer so I see it occasionally, but this exact PR will never get merged. |
|
Hi humans 👋 - this pull request hasn't had any new commits for approximately 3 years. I plan to close this in a month if the pull request doesn't have any new commits by then. In lieu of a stalled pull request, please close this and open an issue instead to revisit in the future. Maintainers may also choose to add If you believe I commented on this issue incorrectly, please report this here. |
|
Long live hidden table columns! |
|
I really need this today -- I have a number of tables with a columns that are complex objects (tables, long dicts) with huge reprs where I need to access the values but never print in a full table. The solution of just selecting out the "columns I want" every time I look at the table is a pain. I'm commenting as incentive to myself to first do the |
|
I was hunting for this feature, it would be really useful for sunpy if the default display columns could be changed and then unhidden by the user, or become unhidden if explicitly indexed etc. |
I've had occasions where a table contains one or more very wide columns that obscure the print output. It would be nice to be able to hide those columns selectively.