cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Did you get an answer that solved your problem? Please mark it as an Accepted Solution so others with the same problem can find the answer easily. X

prime XY plot

Raiko
17-Peridot

prime XY plot

Hi folks,

 

the only reason I'm putting up with prime is that I do have a large data set and MC15 can't handle that many dots. In prime I noticed that once I've changed the trace colour, it became "uneditable"; i.e. I can't change neither colour nor line thickness anymore. Is it just me or a prime bug? and - does anybody know a workaround?

 

Raiko

ACCEPTED SOLUTION

Accepted Solutions

Hi

Issue 1
"the only reason I'm putting up with prime is that I do have a large data set and MC15 can't handle that many dots. In prime I noticed that once I've changed the trace colour, it became "uneditable"; i.e. I can't change neither colour nor line thickness anymore. Is it just me or a prime bug? and - does anybody know a workaround?"

Answer 1
Both forms of creating a 2D graph in Prime at 1,500,000 points you can edit the colour and thickness on my system. In the chart component you need great patience for the editor to come up and changes to come into effect once made.

 

Issue 2
"I have a similar problem, too much data. The data needs to be plotted using a scatter diagram. The Prime scatter data is plotted as black dots. There is also not control in the orientation of the axis's. I want to look down on the X and Y axis. Prime also only allow using the mouse to set the orientation."

Answer 2
Simply plot the X and Y components of the 3D data in a 2D scatter plot.

 

Issue 3
"my sample size is close to 1.5*10^6 points. And I'd like to compare two of them side by side in a graph. Is there a way to read in only every second data point? That way I'd have to handle less." & "I'm aware of using a routine to reduce the number of points to be handled (I've written one). However, I'd like to reduce them already when reading in so that there are less points to start with. I've seen this in Origin where you can choose how many or in which order to read in; say only every second point."

Answer 3
Mathcad cannot parse a large file line by line or data element by data element it reads in vectors/matrices. You can however in the programmable function that splits large data into say every second point put the commands to read the main data file. This means the large amount of memory for the large data set only exist during running of the programmed function.

 

Plotting large data sets.  Here is the path of an optimisation technique.  It is slow needing millions of points.  Mathcad handles the technique but not the plot.  Done in scilab [It is free software].  Over 3,000,000 million blue points and one red point at solution in upper left corner in last swirl.

 

Cheers2220000_15_2.jpg

View solution in original post

7 REPLIES 7
LucMeekes
23-Emerald III
(To:Raiko)

How many points? Mathcad 11 is limited to 500 000 points in a plot.

LM_20190311_PlotSize0.png

I have a plot with 1 million points in Prime 4 (on 64-bit Win10), and can still edit trace colour.

LM_20190311_PlotSize.png

Notice that in order to edit trace properties, you have to select the (Y-axis) variable (SIG[s in the above example) in the plot that you want to change properties of.

 

Success!
Luc

tietjee
15-Moonstone
(To:LucMeekes)

I have a similar problem, too much data.  The data needs to be plotted using a scatter diagram.  The Prime scatter data is plotted as black dots.  There is also not control in the orientation of the axis's.  I want to look down on the X and Y axis.  Prime also only allow using the mouse to set the orientation.  Mathcad v15 allows fixing the orientation using input values.  My solution is to use an external program.  I would assume PTC would want to do this internal to Prime.

 

Let me know if you have a solution to plotting in 3-D.

 

David Tg

 

  

Raiko
17-Peridot
(To:LucMeekes)

llo Luc,

 

my sample size is close to 1.5*10^6 points. And I'd like to compare two of them side by side in a graph. Is there a way to read in only every second data point? That way I'd have to handle less.

 

Raiko

 

P.S. I've also noticed that sometimes the graph tool does not update the graph when I change something like a linear fit that only uses a small subset of datapoints.

Werner_E
25-Diamond I
(To:Raiko)


. Is there a way to read in only every second data point? That way I'd have to handle less.

 


So you are plotting vectors over vector and not a function? It shouldn't be difficult to write a routine which takes a vector as argument and returns a vector with just every n-th element.

You may even use a range to reduce the number of plotted points:

B.PNG

Raiko
17-Peridot
(To:Werner_E)

Hello Werner,

 

I'm aware of using a routine to reduce the number of points to be handled (I've written one). However, I'd like to reduce them already when reading in so that there are less points to start with. I've seen this in Origin where you can choose how many or in which order to read in; say only every second point.

Raiko

Hi

Issue 1
"the only reason I'm putting up with prime is that I do have a large data set and MC15 can't handle that many dots. In prime I noticed that once I've changed the trace colour, it became "uneditable"; i.e. I can't change neither colour nor line thickness anymore. Is it just me or a prime bug? and - does anybody know a workaround?"

Answer 1
Both forms of creating a 2D graph in Prime at 1,500,000 points you can edit the colour and thickness on my system. In the chart component you need great patience for the editor to come up and changes to come into effect once made.

 

Issue 2
"I have a similar problem, too much data. The data needs to be plotted using a scatter diagram. The Prime scatter data is plotted as black dots. There is also not control in the orientation of the axis's. I want to look down on the X and Y axis. Prime also only allow using the mouse to set the orientation."

Answer 2
Simply plot the X and Y components of the 3D data in a 2D scatter plot.

 

Issue 3
"my sample size is close to 1.5*10^6 points. And I'd like to compare two of them side by side in a graph. Is there a way to read in only every second data point? That way I'd have to handle less." & "I'm aware of using a routine to reduce the number of points to be handled (I've written one). However, I'd like to reduce them already when reading in so that there are less points to start with. I've seen this in Origin where you can choose how many or in which order to read in; say only every second point."

Answer 3
Mathcad cannot parse a large file line by line or data element by data element it reads in vectors/matrices. You can however in the programmable function that splits large data into say every second point put the commands to read the main data file. This means the large amount of memory for the large data set only exist during running of the programmed function.

 

Plotting large data sets.  Here is the path of an optimisation technique.  It is slow needing millions of points.  Mathcad handles the technique but not the plot.  Done in scilab [It is free software].  Over 3,000,000 million blue points and one red point at solution in upper left corner in last swirl.

 

Cheers2220000_15_2.jpg

LucMeekes
23-Emerald III
(To:Raiko)

 

Hello Raiko,

Where the number of plot points in mathcad 11  is limited to 500 000, it is limited to 2 000 001 in Prime4. I get a warning when I try to exceed that number.

This seems like a reasonable number (in fact the half-a -million is also resonables, considering thst you cannot actually see every plotted point for a plot containing 16 traces with 31250 points each (that makes the total 500 000), as every point on a landscape A4 would be less than 297/31250=> 0.01 mm.  You really cannot see that.

 

As Werner proposed: Taking every n'th point, or taking the largest in absolute value of every n subsequent points could make sense in reducing the number of points to plot.

 

Success!
Luc

 

 

Announcements

Top Tags