[Date Index] [Thread Index] [Author Index]
Re: Creating and installing one's own packages?
Make the cells you want your package to have as executable to be cells Initialization Cells and Active; use Cell > Properties menu item. Do a Save As on the notebook. You will get a pop-up Auto Save Package dialog window. Click the Create Auto Save Package button in that window. That will do it. Note that if you subsequently move the .m package file and not the source .nb notebook file, then auto-saving changes will not work. Just keep the two in the same directory. AES wrote: > I have a general understanding of what a 'package' is. I understand (I > think) that one can prepare a notebook, and then save (or install?) that > notebook as a package. And somewhere in the fragmented documentation > on packages I also found the sentence: > > "There are also capabilities that allow packages set up to > correspond to notebooks to be maintained automatically." > > N ow, the tutorial "Setting Up Mathematica Packages" gives me a model > or outline or template for a package, which I can use as a guide to > create ("set up?") my own package -- as a notebook, anyway. > > But I'll be g-ddamned if I can find anywhere, in that tutorial or > anywhere else in the Mathematica 6 documentation, explicit instructions > on: > > * How to then convert that notebook into a package, or > where to save it as such after conversion. > > * Where to save the parent notebook itself (or a copy of it), > as an unconverted notebook. > > * How to later modify or edit or update the package itself, > as I'm likely to want to do: Update the package itself? > (And if so, how to get at it?) Update the parent notebook > and then convert -- and Install? -- again? > > [Note that the word "Install" does not seem to appear anywhere in the > "Setting Up Mathematica Packages" tutorial.] > -- Murray Eisenberg murray at math.umass.edu Mathematics & Statistics Dept. Lederle Graduate Research Tower phone 413 549-1020 (H) University of Massachusetts 413 545-2859 (W) 710 North Pleasant Street fax 413 545-1801 Amherst, MA 01003-9305