Community Tip - Your Friends List is a way to easily have access to the community members that you interact with the most! X
Hi ,
Can we modify this function... below the program finds the average of all qs of CPTs in one layer.... Iike if we have 10 cpts each one has 100 qs in one layer ..it sums all the cpts and finds the q of all of them in one layer..
What I need now is to find the average q value of each CPT separately in each layer ..like each brown line in the plot alone .. Can you help me with that .?.
I attached the same sheet you used previously in the thread. Thanks in advance
Hi,
To do anything useful we need the excel data file or files
Cheers
Terry
Sorry I forgot to attach it .. It was attached in the orginal post. Thank you for pointing that out
I hardly can remember and I don't know what CPTs, qs and "the q" should be.
I guess layers are depths limited by values given somehow in a nested vector z? Or, no, I also see a vector stop!?
Actually I don't know what kind of change you would need and have no idea what i did way back with this little program you show.
10 vertical lines where we now have just one? How would you distinguish between all of them?
Which data structure you do expect any results (whatever they may be) to be in? As I see it its currently a simple 8x1 vector of pressure values (avg).
I see that I had played around a lot with various plots and calculations. Maybe it would help to delete all elements in the sheet which are not mandatory to the final result...
And please - don't use variable names like "rows" which is also the name of a built in function!!
EDIT: Just had a quick look at the sheet and I guess what you are looking for are 14 separate average values for every of the 8 layers, right?
I also guess that you would not need any plot as this would be too confusing anyway and the program you show is only calculating the values (the data structure for the plot was made in in a different routine - Avg)
So the question still would be in which way you would need the data returned.
Possibilities are:
a 14x8 matrix,
a 8x14 matrix,
a nested 14x1 vector which consists of 8x1 vectors,
a nested 8x1 vector which consists of 14x1 vectors.
or anything else?
Easiest way to modify the existing program was to create a nested 14x1 vector but of course it would not be difficult to convert it to any of the other suggested data structures if needed.