r/excel•
_Iridium

Trying to pull values from a sheet where data is in a 2D matrix defined with string column and row headers

solved

Hi r/Excel!

I am trying to do a 2D lookup of data within a matrix.

Here is the nitty gritty: On Sheet1, I have a 2D table, with row labels (all in column 1) such as Source 1 Source 2 Source 3 And on the top of the sheet I have my column headers of Destination1, Destination2, Destination3, etc. Here is what it looks like:

	Destination1	Destination11	Destination21	Destination31
Compound 1	          9	               3	                5
Compound 2	          3	              6	               18
Compound 3	          10	             20	               11
Compound 4	          18	             20	               17
Compound 5	           16	             10	                1
Compound 6	           5	               9	                2
Compound 7	           16	              13	                13
Compound 8	           19	               19	                3
Compound 9	            5	              20	                2
Compound 10	          17	                 2	               14

Within that matrix are all the transfer volumes that each source must put into each position. So again, I have strings that are my row and column headers, with floats comprising the data of the table.

On a second sheet, I have a list of combinations that I would like to pull that combination data from Sheet1:

A                                 B                        C
Destination21             Compound8             [pulled data here]

I would like to pull the data from Sheet1 for each combination in Sheet3. (in the above the PULLED DATA should be 19) I have been trying various VLOOKUP functions which include a MATCH function, but mostly I just get returned a "#N/A". It looks like all my parameters are correct. The kicker here as that I need Excel itself to identify the correct column and row to look in based off of the string headers, as there are 200 rows and 40 columns. So it needs to find that information and THEN pull the data from the sheet.

Any ideas? Any idea what I am even talking about? haha. I'm just stuck.

Thanks!

EDIT: I can't seem to make my columns even, sorry.

Posted Jan 11, 2017, 11:57 PM UTC · edited

214
Loading comments…