Need Help with multiple criteria labelled data

clueless_excel

New Member
Joined
May 1, 2023
Messages
4
Office Version
  1. 365
Platform
  1. Windows
So my data is labelled A1-5, from A-Z. I want to add labels into another column based of these i.e., A,B,C,D are 3, E,F,G,H are 20, I and J are 10 for example. Any advice on the best way to do this? I've tried to do a bunch of nested IFs but I reach the 64 limit before it covers all the possibilities.

1682956621793.png

This is how the data looks, I want to enter specific labels for start and end point based off the vial number but am unsure of the best way to solve this. Any advice?
 

Excel Facts

Can Excel fill bagel flavors?
You can teach Excel a new custom list. Type the list in cells, File, Options, Advanced, Edit Custom Lists, Import, OK
lookup table
A to Z

= index( cell to bring back, Match(left(cell,1),range with alphabet , 0 ))

Book6
ABCDEFGHI
1
2a13a3
3a23b3
4a33c3
5f120d3
6f220e3
7f320f20
8f420g20
9I110h20
10I210i10
11I310j10
12k10
Sheet1
Cell Formulas
RangeFormula
C2:C11C2=INDEX($I$2:$I$12,MATCH(LEFT(A2,1),$H$2:$H$12,0))


Note: Images are difficult to see , and also requires that I input all the data myself, which means I may make an error, which is very time consuming, and from my point of view less likely to get a response, if a complicated spreadsheet. Plus we cannot see any of the formulas used.

Therefore -

A SMALL sample spreadsheet, around 10-20 rows, would help a lot here, with all sensitive data removed, and expected results mocked up and manually entered, with a few notes of explanation.

MrExcel has a tool called “XL2BB” that lets you post samples of your data and will allow us to copy/paste your sample data into our Excel spreadsheets, saving a lot of time.

You can also test to see if it works ok, in the "Test Here" forum.

OR if you cannot get XL2BB to work, or have restrictions on your PC

then put the sample spreadsheet onto a share

I only tend to goto OneDrive, Dropbox or google docs , as I'm never certain of other random share sites and possible virus.
Please make sure you have a representative data sample and also that the data has been desensitised, remember this site is open to anyone with internet access to see - so any sensitive / personal data should be removed

Make sure you set any share or google to share to everyone
 
Upvote 0
lookup table
A to Z

= index( cell to bring back, Match(left(cell,1),range with alphabet , 0 ))

Book6
ABCDEFGHI
1
2a13a3
3a23b3
4a33c3
5f120d3
6f220e3
7f320f20
8f420g20
9I110h20
10I210i10
11I310j10
12k10
Sheet1
Cell Formulas
RangeFormula
C2:C11C2=INDEX($I$2:$I$12,MATCH(LEFT(A2,1),$H$2:$H$12,0))


Note: Images are difficult to see , and also requires that I input all the data myself, which means I may make an error, which is very time consuming, and from my point of view less likely to get a response, if a complicated spreadsheet. Plus we cannot see any of the formulas used.

Therefore -

A SMALL sample spreadsheet, around 10-20 rows, would help a lot here, with all sensitive data removed, and expected results mocked up and manually entered, with a few notes of explanation.

MrExcel has a tool called “XL2BB” that lets you post samples of your data and will allow us to copy/paste your sample data into our Excel spreadsheets, saving a lot of time.

You can also test to see if it works ok, in the "Test Here" forum.

OR if you cannot get XL2BB to work, or have restrictions on your PC

then put the sample spreadsheet onto a share

I only tend to goto OneDrive, Dropbox or google docs , as I'm never certain of other random share sites and possible virus.
Please make sure you have a representative data sample and also that the data has been desensitised, remember this site is open to anyone with internet access to see - so any sensitive / personal data should be removed

Make sure you set any share or google to share to everyone
Thank you I appreciate it, didn't think to try INDEX. Looks like its working now
 
Upvote 0
you are welcome

i'm sure others may answer with better solutions then a table - maybe choose , or something similar
 
Upvote 0
you are welcome

i'm sure others may answer with better solutions then a table - maybe choose , or something similar
Thanks. Honestly if it works it'll be good enough for the moment haha. Just a follow up question, how are you able to have it only look for the letters specifically. I'm relatively new to coding so its a bit confusing to understand haha
 
Upvote 0
the value it is looking up - is
left(cell,1)
so that takes the first character in the cell
which in your case should be the alphabet

it is then using that to find that letter within the list A to Z - which i assumed you have filled in , in the table column H
once matches then it knows what row to lookin - and the index looks in that row in the column H and returns the value from column I

you could have used an vlookup() - i just always use index/match - as you can also specify columns to the left of the lookup - not possible with vlookup in its default use - there is a way - but not as written

have a read here - for explanation of index/match

if you goto MREXCEL youtube site
there are a few videos on the subject
 
Upvote 0
the value it is looking up - is
left(cell,1)
so that takes the first character in the cell
which in your case should be the alphabet

it is then using that to find that letter within the list A to Z - which i assumed you have filled in , in the table column H
once matches then it knows what row to lookin - and the index looks in that row in the column H and returns the value from column I

you could have used an vlookup() - i just always use index/match - as you can also specify columns to the left of the lookup - not possible with vlookup in its default use - there is a way - but not as written

have a read here - for explanation of index/match

if you goto MREXCEL youtube site
there are a few videos on the subject
Ah right thank you, appreciate the explanation and the literature. Useful stuff to know haha
 
Upvote 0

Forum statistics

Threads
1,216,079
Messages
6,128,687
Members
449,464
Latest member
againofsoul

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