Mathematica 9 is now available
Services & Resources / Wolfram Forums / MathGroup Archive
-----

MathGroup Archive 2009

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

Search the Archive

Re: How can I change the default path for the function "Put"?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg104662] Re: How can I change the default path for the function "Put"?
  • From: Bill Rowe <readnews at sbcglobal.net>
  • Date: Fri, 6 Nov 2009 05:16:20 -0500 (EST)

On 11/5/09 at 3:49 AM, jian0730 at gmail.com (Jian) wrote:

>In my computer, when I use "Put" (or ">>") to save some data to the
>computer, Mathematica automatically outputs the data to a network
>hard disk, where the "My Documents" folder is.  Although I know I
>can check this path using "$InitialDirectory" command, I do not know
>how to change it to a local folder.  Would anyone help me, PLZ?

Put saves data in the current working directory. The current
working directory can be set to any directory you have the
ability to read/write using SetDirectory. For example, on a Mac

SetDirectory["~/Desktop"]

will set the working directory to the current users desktop
directory. Or assuming the notebook you are using has been saved
to the hard drive

SetDirectory@NotebookDirectory[]

will set the working directory to the directory containing the
notebook this is executed in.




  • Prev by Date: Writing a graphic to a notebook, cont
  • Next by Date: Monitoring using Mathematica
  • Previous by thread: Re: How can I change the default path for the function "Put"?
  • Next by thread: Contour plot labels with higher precision