Delet masked points

http://www.originlab.com/forum/topic.asp?TOPIC_ID=7831&SearchTerms=IsMask
http://www.originlab.com/forum/topic.asp?TOPIC_ID=3453

1.
!comments: [-><
Select Worksheet : Extract Worksheet Data…

To Delete:
Select the column with Masked values (presumably your Y column)
Click the => button to create an Alias (in this example : B)
In the Condition text box, type
B[i]!=0
Click Test — select if true button
(This causes only those rows with masked values to be selected.)
Click the Close button
Select Edit : Delete from the menu (NOT the Delete key)
All rows with masked values are removed.

To Copy:
Select the column with Masked values (presumably your Y column)
Click the => button to create an Alias (in this example : B)
In the Condition text box, type
B[i]==0
Select ‘Extract to New Workbook’ as Output
Click OK
New Workbook will contain only those rows without masked values.

2.
// Get number of rows in current sheet
irows = wks.maxrows;
// Save name of current sheet in %a variable
%a=%h;
// Create a new sheet
win -t;
%z = %h;
// Initialize counter
inum = 1;
// Loop over all rows of source sheet
for(ii=1; ii<=irows; ii++) { // If cell in 1st col is masked… if( 1 != ismasked(ii, %(%a,1)) )
{
for (jj=1; jj<=wks.nCols; jj++) { // Copy over to destiation %(%h,jj,inum) = %(%a,jj,ii); } // Update counter inum++; } } wks.export.cntrl = 2; save -wh %h %1; win -c %h;

Go to Top of Page
Advertisements

About yhtian

I am an academic researcher working on Offshore Geotechnical Engineering. My blog aims to write down some work related trivial things and tricks about software, programming. It is basically a memo for me to back up some thoughts and small details. But I am more than happy if someone would visit and discuss.
This entry was posted in Uncategorized. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s