Function help, (logic?) assigning a value to a cell based on another

jdcollins88

New Member
Joined
Jan 28, 2013
Messages
5
Hello, I am trying to fill in the Net height in the below table based on the Net assignment located next to species. If Net=A then Net height should = 2.6 for MYLU but should be 10.4 for MYSO. I've tried a nested IF function =IF(B1="A",C1 IF(B1="B", D1)) but it returns an error. I could do it by hand if I didn't have 10K records :eek:
SpeciesNetNet A HeightNet B HeightNet Height
MYLUA2.65.2
MYSOA10.410.4
MYSEB5.22.6
MYSEA10.42.6

<tbody>
</tbody>

Thanks for the help.
Jason
 

Excel Facts

What is =ROMAN(40) in Excel?
The Roman numeral for 40 is XL. Bill "MrExcel" Jelen's 40th book was called MrExcel XL.
This is a little unclear.

Try
=IF(AND(A1="MYLU",B1=2.6),5.2,IF(AND(A1="MYSO",B1=10.4),10.4,2.6))
 
Upvote 0
The reality is a bit more complex I was trying to keep it as simple as possible. Basically the "net" and net height are appended tables, and the species are coming from different locations meaning net A is not always the same length, but the net heights correspond to the height of those nets (e.g. A, B) at that location. The end result would be two columns one with species and one with the height of the net that species was captured in. So if species X was captured in net C I want to assign it the height designated in the corresponding column titled net C. I hope this clears it up a bit.
 
Upvote 0

Forum statistics

Threads
1,215,554
Messages
6,125,487
Members
449,233
Latest member
Deardevil

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top