[Scilab-users] Data from XCos plots?

classic Classic list List threaded Threaded
4 messages Options
Pndsc Pndsc
Reply | Threaded
Open this post in threaded view
|

[Scilab-users] Data from XCos plots?

I was wondering if theres a way to export data from Xcos plots that show the
result of simulations. Graphs are OK but I need to interrogate the raw
values.

Is there a way to export to CSV or something? I'm assuming that its
something simple that I've missed.



--
Sent from: http://mailinglists.scilab.org/Scilab-users-Mailing-Lists-Archives-f2602246.html
_______________________________________________
users mailing list
[hidden email]
http://lists.scilab.org/mailman/listinfo/users
nikolay nikolay
Reply | Threaded
Open this post in threaded view
|

Re: Data from XCos plots?

Dear Pndsc!

It is possible. If you have figure with axis from Xcos model then you can get its data:

    a = gca();
    x = a.children.data(:,1);
    y = a.children.data(:,2);

and then manipulate them as you need.

--
With best regards,
Ph.D.,
associate professor at MPEI,
IEEE member,
maintainer of Mathieu functions toolbox for Scilab,
Nikolay Strelkov.



вс, 13 янв. 2019 г. в 12:45, Pndsc <[hidden email]>:
I was wondering if theres a way to export data from Xcos plots that show the
result of simulations. Graphs are OK but I need to interrogate the raw
values.

Is there a way to export to CSV or something? I'm assuming that its
something simple that I've missed.



--
Sent from: http://mailinglists.scilab.org/Scilab-users-Mailing-Lists-Archives-f2602246.html
_______________________________________________
users mailing list
[hidden email]
http://lists.scilab.org/mailman/listinfo/users

_______________________________________________
users mailing list
[hidden email]
http://lists.scilab.org/mailman/listinfo/users
PySciMAn PySciMAn
Reply | Threaded
Open this post in threaded view
|

Re: Data from XCos plots?

Is there a way to export Xcos data during simulation the "to workspace" block only exports data after the simulation?

On Sun, 13 Jan 2019, 6:56 pm Nikolay Strelkov <[hidden email] wrote:
Dear Pndsc!

It is possible. If you have figure with axis from Xcos model then you can get its data:

    a = gca();
    x = a.children.data(:,1);
    y = a.children.data(:,2);

and then manipulate them as you need.

--
With best regards,
Ph.D.,
associate professor at MPEI,
IEEE member,
maintainer of Mathieu functions toolbox for Scilab,
Nikolay Strelkov.



вс, 13 янв. 2019 г. в 12:45, Pndsc <[hidden email]>:
I was wondering if theres a way to export data from Xcos plots that show the
result of simulations. Graphs are OK but I need to interrogate the raw
values.

Is there a way to export to CSV or something? I'm assuming that its
something simple that I've missed.



--
Sent from: http://mailinglists.scilab.org/Scilab-users-Mailing-Lists-Archives-f2602246.html
_______________________________________________
users mailing list
[hidden email]
http://lists.scilab.org/mailman/listinfo/users
_______________________________________________
users mailing list
[hidden email]
http://lists.scilab.org/mailman/listinfo/users



_______________________________________________
users mailing list
[hidden email]
http://lists.scilab.org/mailman/listinfo/users
fmiyara fmiyara
Reply | Threaded
Open this post in threaded view
|

Re: Data from XCos plots?

In reply to this post by nikolay

Probably it is

a = gca();

x = a.children.children.data(:,1);
y = a.children.children.data(:,2);

since a.children doesn't have the "data" proerty, but its child is of type "Polyline" which does have the "data" property

Federico Miyara   

On 13/01/2019 07:55, Nikolay Strelkov wrote:
    a = gca();
    x = a.children.data(:,1);
    y = a.children.data(:,2);



Libre de virus. www.avast.com

_______________________________________________
users mailing list
[hidden email]
http://lists.scilab.org/mailman/listinfo/users