comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Deleting specific instances of the structure
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Deleting specific instances of the structure [message #87353 is a reply to message #87351] Mon, 27 January 2014 15:01 Go to previous messageGo to previous message
Matthew Argall is currently offline  Matthew Argall
Messages: 286
Registered: October 2011
Senior Member
> For eg, out of the 10 structure instances, domain[2], domain[6],domain[7] are the empty ones and needs to be deleted and the final result should have only 7 elements in the structure array.

If you already know the structures you want to keep, you can just pick them out...

IDL> domain = REPLICATE({frame :0, particles : fltarr(5,6000),link : [-1,-1]}, 10)
IDL> iKeep = [0,1,3,4,5,8,9]
IDL> domain = domain[iKeep]
IDL> Help, domain
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Previous Topic: urgent-outliers removal
Next Topic: Instances of structure array with varying no. of elements

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Thu Oct 09 07:48:09 PDT 2025

Total time taken to generate the page: 1.43716 seconds