ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   assigning value to a column based on a table of values (https://www.excelbanter.com/excel-discussion-misc-queries/65003-assigning-value-column-based-table-values.html)

Jacob

assigning value to a column based on a table of values
 
I am correcting an exam and I have automatically generated the score of the
students. These I have in columns. Further I have a translation code that
showes how a score relates to a grade. this is shown below. Here the interval
from min to max is the score that produce the grade. For example if the score
is between 2 and 5 the grade is 5.

How do I make the translation from score to grade automatically?

min max grade
0 2 3
2 5 5
5 6 6
6 7 7
7 8 8
8 11 9
11 18 10
18 23 11

Jacob

Bob Phillips

assigning value to a column based on a table of values
 
Just use

=VLOOKUP(E1,B2:C9,2)

where E1 holds the score to be graded, B2:C9 holds the max and grade
columns.

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"Jacob" wrote in message
...
I am correcting an exam and I have automatically generated the score of

the
students. These I have in columns. Further I have a translation code that
showes how a score relates to a grade. this is shown below. Here the

interval
from min to max is the score that produce the grade. For example if the

score
is between 2 and 5 the grade is 5.

How do I make the translation from score to grade automatically?

min max grade
0 2 3
2 5 5
5 6 6
6 7 7
7 8 8
8 11 9
11 18 10
18 23 11

Jacob




Pete

assigning value to a column based on a table of values
 
Your max values are the same as the min values for the next grade. If
someone has a score of 2 or 5, which grade would be awarded? Assuming
that it would be the higher grade, the following should do what you
want:

=VLOOKUP(A1,$H$2:$J$9,3,TRUE)

where I have assumed your table (with headings) occupies cells H1 to
J9, and that the raw score is in A1. You can enter the formula, say, in
B1 and copy down.

Hope this helps.

Pete


Jacob

assigning value to a column based on a table of values
 
Thanks to you both

"Jacob" skrev:

I am correcting an exam and I have automatically generated the score of the
students. These I have in columns. Further I have a translation code that
showes how a score relates to a grade. this is shown below. Here the interval
from min to max is the score that produce the grade. For example if the score
is between 2 and 5 the grade is 5.

How do I make the translation from score to grade automatically?

min max grade
0 2 3
2 5 5
5 6 6
6 7 7
7 8 8
8 11 9
11 18 10
18 23 11

Jacob



All times are GMT +1. The time now is 07:42 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com