PDA

View Full Version : Convert "N"-"F"-"P" Values to Numbers then Calculate an Average



aaghd
04-30-2008, 09:06 AM
Hello, :hi:

I need an Excel formula in cell E2 that will find the letter "N" in range (A2thruD2) and assign it the value of Zero, in the same range find all the letter "F" and assign it the value of 100, and find the letter "P" and assign it the value of 50 then average all the values.

Thanks in advance for your assistance.

Cause I am :banghead:

aaghd

ALe
04-30-2008, 09:47 AM
something like that?

=(COUNTIF(A1:D1;"N")*0+COUNTIF(A1:D1;"F")*100+COUNTIF(A1:D1;"P")*50)/4

ALe
04-30-2008, 09:49 AM
fuc...smiles

sorry

=(countif(A1:D1;"N")*0+countif(A1:D1;"F")*100+countif(A1:D1;"P")*50)/4

aaghd
04-30-2008, 10:10 AM
Thanks so very much ALe Boffi,

I changed the range and when I post it it gives me an error message - it is highlighting the second reference of my range. The range would be B2-E2. I can't see anything wrong though. It just doesn't seem to like the range.

aaghd

ALe
05-08-2008, 09:59 AM
Sorry I didn't get the problem.

If you have changed the range, just substitute in the formula all the references to the old range with the references to the new one.