help-octave
[Top][All Lists]
Advanced

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

Re: plotting the data given below


From: Juan Pablo Carbajal
Subject: Re: plotting the data given below
Date: Tue, 31 Jan 2012 10:59:17 +0100

On Tue, Jan 31, 2012 at 8:38 AM, asha g <address@hidden> wrote:
> I have the following data which I am trying to plot and get the error given
> below. Please tell me what is happening.
> Thanks
> Asha
>
>
>
> q :
> (1, 1) ->  0.050034
>   (2, 1) ->  0.048674
>   (3, 1) ->  0.047482
>   (4, 1) ->  0.046456
>   (5, 1) ->  0.045595
>   (6, 1) ->  0.044894
>   (7, 1) ->  0.044352
>   (8, 1) ->  0.043966
>   (9, 1) ->  0.043734
>   (10, 1) ->  0.043658
>
> X =
>
>  Columns 1 through 8:
>
>    0.00000   0.05936   0.11872   0.17808   0.23744   0.29680   0.35616
> 0.41551
>
>  Columns 9 and 10:
>
>    0.47487   0.53423
>
> plot(X,q,'y*',"markersize",6)
>
>
>
> error: octave_base_value::write(): wrong type argument `sparse matrix'
> error: called from:
> error:   /usr/share/octave/3.2.3/m/plot/__go_draw_axes__.m at line 1531,
> column 5
> error:   /usr/share/octave/3.2.3/m/plot/__go_draw_axes__.m at line 1337,
> column 4
> error:   /usr/share/octave/3.2.3/m/plot/__go_draw_figure__.m at line 92,
> column 3
> error:   /usr/share/octave/3.2.3/m/plot/gnuplot_drawnow.m at line 91, column
> 5
> error:   /usr/share/octave/3.2.3/m/plot/print.m at line 699, column 7
> error:   /home/ashag/Desktop/passivedendrite/cabunpa2sevoltNoct2.m at line
> 146, column 1
>
>
>
>
>
>
>
> _______________________________________________
> Help-octave mailing list
> address@hidden
> https://mailman.cae.wisc.edu/listinfo/help-octave
>

Hi,
As of Octave 3.4.3 the function plot does not accept sparse arguments.
You have to flatten (or what-ever-is-called) your matrix before
plotting:

plot ( X, full(q), 'y*', "markersize", 6)

-- 
M. Sc. Juan Pablo Carbajal
-----
PhD Student
University of Zürich
http://ailab.ifi.uzh.ch/carbajal/


reply via email to

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