help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

csvread Problem on Octave 3.8.0 Mac OS X Yosemite


From: jennawebb
Subject: csvread Problem on Octave 3.8.0 Mac OS X Yosemite
Date: Thu, 10 Sep 2015 10:56:48 -0700 (PDT)

Let me start off by saying that I am new to using a Mac, and relatively new
to using Octave. The problem I am having involves the csvread function. I
just want to test whether certain Octave scripts that work on Windows
machines also work on Macs.

I have a script that uses the csvread function, with the file saved as a CSV
for the Mac. Here is what the code for that looks like: 

    data = csvread('normaldata.csv');

For reference, the  normaldata.csv
<http://octave.1599824.n4.nabble.com/file/n4672513/normaldata.csv>   file
(the link is to a file that is saved as a Windows csv, but I am sure that it
is saved as a Mac CSV when I am using that machine) is a 16x12 matrix, with
numerical values only. When this data is read in, for some reason it is
represented as a complex number, and it is only a row matrix (1x177) instead
of a 16x12 (and the dimensions don't match up). Another thing I just noticed
is that some of the entries in the CSV file actually show up in the
imaginary part of the complex number. Each number in column 12 (the last
column) includes the next entry (column 1, next row) in the imaginary part.
For example, row1,col12 entry is 5.18 and row2,col1 entry is 3.7. In the
matrix that is read in using csvread, instead of 5.18 being read in as
simply the number 5.18, it is read in as 5.18 + 3.7i.


I'm wanting to use this matrix to split each column into separate arrays,
but since it is reading it in as one line I cannot do that. I'm sorry if
this is confusing, I can include parts of the files and possibly pictures if
need be.

Thanks in advance for any help that can be offered.

Jenna



--
View this message in context: 
http://octave.1599824.n4.nabble.com/csvread-Problem-on-Octave-3-8-0-Mac-OS-X-Yosemite-tp4672513.html
Sent from the Octave - General mailing list archive at Nabble.com.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]