[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Picking up the correct index values
From: |
Przemek Klosowski |
Subject: |
Re: Picking up the correct index values |
Date: |
Wed, 27 May 2020 20:52:21 -0400 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.2.1 |
On 5/27/20 9:54 AM, GK19 wrote:
you cant combine them. It should be 4 arrays. Can you please help me
Octave/Matlab is great at expressing mathematical relationships over
large datasets. This implies that you actually pack your data into few
large arrays and try to find common operations that apply to all of your
values.
If you insist on separating your data into distinct variables, you
deprive yourself of the strength and expressiveness of the language, to
the point that you might as well use Basic or C. Note how Doug packed
your data into the t1/t 2 arrays, so that he can probe them for equality.
If you organize your data as an array of measurements v(NorP,
measurement, transistorNumber), so that v(1,3,2) is the third Nwell
voltage of the second transistor,
v(:,:,1) = [ 0.0 0.9 1.2; -1.8 -1.2 -1.0]
v(:,:,2) = [ 0.9 0 -0.1 ; -1.2 0.2 0.8]
you are not limited to e.g. number of transistors you measured and
number of measurements per transistor, and you could access the data e,g
for the second transistor as v(:,:,2), and get all Nwell voltages as
squeeze(v(1,:,:))
(squeeze() eliminates the extra singleton dimension so that you get a
regular 2D array)
or get the first measurement for all transistors:
squeeze(v(:,1,:))
Then, you can use the ismember() function :
ismember(squeeze(:,2,3), v)
or just loop and compare.
THis is not necessarily obvious if you are used to every value being in
its own variable, but getting used to this way of representing data is
very useful when you're dealing with large data sets.