Random selection of rows from a 2D array then subset both the rows that were selected and those that were not. Please see message below.

For example, I have a 2D array with 46 rows and 400 columns. I would like to randomly select 46 data rows from the 2D array. By doing the random selection it means that not all individual 46 rows will be selected some rows may appear more than once as there may be some duplicates or triplicates in the random selection. The importan thing is that we will have randomly selected 46 rows of data (no matter that some rows appear more than once). Then I would like to subset these randomly selected 46 data rows (some which will be duplicated, or triplicated, etc.) and then also find and subset the rows that were not selected. Does this make sense? Then i would like to do this say 10 times for this data set. So that then I will have 2 by 10 data sets: the first 10 each with 46 rows and the other 10 with n rows depending on how many WERE NOT randomly selected. i hope that my explanation is clear. I am relatively new to Labview. It is really great so I am getting better! If anyone can help me with this problems it will be great. RVR

Start by generating randon #s between 0 and 45. Run a for loop X times and in it use the random function, multiply the result by X and round down (-infinity). You can make this into a subVI, which you can reuse later. In the same loop, or in a different one, use Index Array to extract the rows which were selected (wiring the result out of the loop with auto indexing causes it to be rebuilt into a 2D array).
One possible solution for the second part would be to go over the array of randomly generated numbers in a for loop and use Search 1D Array to find each of the numbers (i). If you get -1, it means the row wasn't selected and you can extract it.
I hope this puts you on the right path. If not, don't be afraid to ask more.
To learn more about LV, I suggest you read the LabVIEW user manual. Also, try searching this site and google for LabVIEW tutorials. Here and here are a couple you can start with. You can also contact your local NI office and join one of their courses.
In addition, I suggest you read the LabVIEW style guide.
Try to take over the world!

Similar Messages

Maybe you are looking for

  • When I login at startup a random folder opens

    Ok, this is weird. First of all this is my first Mac and I'm having a really difficult time figuring something out. Before I do a shutdown I will close every finder window and program. The next time I turn my computer on and login I will be greeted w

  • Cisco ISE 1.2 monitoring and Reporting

    Hi Ali We're trying to determine how many addtional Base licenses we have to purchase in order to be compliant in our Cisco ISE 1.2 platforms (already have 1500 CISE 1.2  Base licenses in production). Is there any means to monitoring (e.g SNMP pollin

  • My Macbook pro was stolen before I had time to register it and I want to inform apple

    My MacBook pro was stolen two days after I purchased it. I did not register my product nor did I have time to set up any tracking software. I still have the box and the registration/Serial Number. How can I inform Apple in hopes that they can help me

  • Is this possible in a single query?????

    While I don't think this is possible in a single query, I definately don't have the background the experts here have.  I have a request to identify all shipments in a period/range of periods that have a payment transaction.  For those shipments, the

  • Reoprt execution time out for particular Plant

    Hi GURUS, I am having ECC6.0 with MSSQL2005 combination here. One of my Sales register report executes fine with local plants but for plant which is about 2000 Km from here it gets timed out when executed. So i ran that report in background. It succe