取消
顯示結果 
搜尋替代 
您的意思是: 

How to find the between value of one limit to another limit and also find the percentage of between values.

Hi Everyone, 

             I want to find the between values in the array. For example:- I give 95 to 115, the values between 95 to 115 will be shown in the array indicator. After I find how many percent of value present in between (95 to 114) ; (114 to 135) ; (135 to 155); (155 to 170) ; (170 to 200) out of 200. This is a problem I am facing in my part of my coding.

 

I do this concept but I don't know it is right or wrong...

 

Anyone knows this concept please drop your comment...

 

And program file is also attached below.

            

0 積分
1 條訊息(共 7 條)
1,991 檢視

Finding the values is ok as you get the values you need where you need it. Maybe you will find a better (more compact) way to do it instead of X for loops.

 

But when your are making the percentage computing, this is wrong if I'm understanding correctly.

You need to know how many values there is in each array and divide this by the number of values in the starting array, then use array size instead of summing values.

 

Correct me if i've misunderstood.

0 積分
2 條訊息(共 7 條)
1,975 檢視

OK, I WILL TRY THIS THANK YOU FOR YOUR COMMENT.....

0 積分
3 條訊息(共 7 條)
1,960 檢視

@Defaphe wrote:

Finding the values is ok as you get the values you need where you need it. Maybe you will find a better (more compact) way to do it instead of X for loops.

 

But when your are making the percentage computing, this is wrong if I'm understanding correctly.

You need to know how many values there is in each array and divide this by the number of values in the starting array, then use array size instead of summing values.

 

Correct me if i've misunderstood.


Use a histogram of Input Array[ ].  This will give you a count of values between limit pairs as an array<call that H[ ].  100*H[ ] / (Size(Input Array[ ])+1) will yield an array of bin sizes as percent of population. 

 


"Should be" isn't "Is" -Jay
0 積分
4 條訊息(共 7 條)
1,945 檢視

Thank you so much I will try this also...

 

0 積分
5 條訊息(共 7 條)
1,871 檢視

@guru13 wrote:

Thank you so much I will try this also...

 


Don't forget to post back with your revised code!


"Should be" isn't "Is" -Jay
0 積分
6 條訊息(共 7 條)
1,861 檢視

while the code is attached below........

0 積分
7 條訊息(共 7 條)
1,810 檢視