MathGroup Archive 2007

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Best way to save data in notebooks

  • To: mathgroup at
  • Subject: [mg82004] Re: Best way to save data in notebooks
  • From: Yaroslav Bulatov <yaroslavvb at>
  • Date: Tue, 9 Oct 2007 05:37:22 -0400 (EDT)
  • References: <fea47j$i20$><feca2u$fmc$>

Thanks for the tips. "Compress" helps, but it can still take a long
time for the FrontEnd to render the output cell. Is it possible to
tell Mathematica to collapse the output cell without displaying it?

On Oct 7, 9:01 pm, AES <sieg... at> wrote:
> In article <fea47j$i2... at>, John Fultz <jfu... at>
> wrote:
> > > I'd like to have "data" saved in the notebook, so that when I open it,
> > > I can replot the data. My current solution is to copy and paste the
> > > data manually into a separate mathematica cell (ie, data={1,2,3...}),
> > > but that causes the front-end to freeze when largedatafile.csv is too
> > > large.
> > > Yaroslav
> > Assuming you're using version 6, you could get a compressed form by doing...
> > Compress[data]
> > ...then modify the output cell by putting the caret at the beginning and
> > typing
> > data=Uncompress@
> > which will convert the Output cell into an Input cell you can evaluate in the
> > future.  It's not quite as fast and convenient as DumpSave, of course, but if
> > you really insist on keeping the data in the notebook, it'll work.
> John,
> Thanks very much.  This is one of those very useful tricks that might be
> difficult for an ordinary user to develop by himself, but can be
> understood and used once you've seen it.
> As an extension to it:  Suppose the data in question is not necessarily
> a Plot, maybe just a List; said List is the Output cell created by
> executing an Input cell; and each time one executes said Input cell one
> wants to save the new result **and not erase any of the old ones** that
> may still be sitting there -- except of course one doesn't want to go
> too far in doing this if the List is large, and one will want to delete
> selected older Saved Lists from time to time.
> I think I can actually figure out a procedure that can do this task by
> myself (maybe add a random name or date to the List name each time you
> Save one?).  But of course if someone more skilled than me wanted to lay
> out a template for doing this, I'd be delighted to use it instead.

  • Prev by Date: Re: equation trecker questions.
  • Next by Date: Re: Plot3D with NDSolve
  • Previous by thread: Re: Best way to save data in notebooks
  • Next by thread: Re: Re: Best way to save data in notebooks