Re: Using a string variable as a filename #2

Previous Topic Next Topic
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Re: Using a string variable as a filename #2

On Wed, Jul 5, 2017 at 9:23 PM, Charl Muishond <[hidden email]> wrote:

> Hi Juan,
> I use Octave but struggle to have my data saved.
> I want to do it as follows:
> Fname = input(“ Enter filename to save data to: “);
> How can I proceed from here so that whatever filename I type in would be used to save the data?
> I truly hope you can assist.
> Thanking you in advance
> Kind Regards/ Vriendelike Groete
> Charl Muishond

Hi, please use the help mailing list for requesting help.

To read a string from user input do

fname = input ("Enter filename to save data to: ", "s")

then you can use Octave's save command if that suits your need. Check
the help of input and save using

help input


help save

get used to use the "help" command, as well as "lookfor", and the TAB
key. Also always try to use the latest stable release (currently


JuanPi Carbajal
Public GnuPG key: 9C5B72BF
"Why is thought, being a secretion of the brain, more wonderful than
gravity, a property of matter?"
- C. Darwin

Help-octave mailing list
[hidden email]