Solved

Excel data segment

Posted on 2013-01-11
8
466 Views
Last Modified: 2013-01-11
I've got a lot of data in Excel and would like to divide them into segments according to 2 columns' value:

Asset                              No of product        Segment
> 1000000                >10                        Premium 1
> 1000000              >=10 & <100      Premium 2
> 1000000               >100                        Premium 3
>50000 & <=1000000      >10      Smart 1
>50000 & <=1000000       >=10 & <100      Smart 2
>50000 & <=1000000      >100      Smart 3
<=50000                                    >10       Normal 1
<=50000                               >=10 & <100      Normal 2
<=50000                                  >100      Normal 3


Are there any smart ways to lookup the segments?
0
Comment
Question by:hkgal
  • 5
  • 3
8 Comments
 
LVL 18

Expert Comment

by:xtermie
ID: 38767137
Add a nested if statement with and AND operator and an OR operator that classifies them in a third column -
Copy your conditions on a separate location
You could get something like in C2
=if(AND(A2=$E$2;B2=$F$2);"Premium1";if(AND(A2=$E$3;B3=$F$2);"Premium2";....

(substitute ; to , depending on your regional settings

assuming that column A holds the Asset values and B the No of Product and columns E and F hold the conditions for the classification

Instead of getting a very complicated nested if, maybe you can group together conditions
i.e. I see that from your data Premium 1, Normal 1 and Smart 1 change due to the first condition (Asset).  Can I have an excel with sample data?
0
 
LVL 18

Expert Comment

by:xtermie
ID: 38767147
An easy way would be to color code these based on conditional formatting.
0
 
LVL 18

Expert Comment

by:xtermie
ID: 38767155
What classification is obtained (segment) when No of product is equal to 100????
0
Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

 

Author Comment

by:hkgal
ID: 38767171
I am using Excel 2003, but when I used nested If function, it reach condition limit after 7 If function set..
0
 
LVL 18

Assisted Solution

by:xtermie
xtermie earned 500 total points
ID: 38767181
I broke down your conditions into two conditions
One that based on the Asset produces the Part A of the segment (premium, smart, normal) and one based on the No of product produces the Part B of the segment (1, 2, 3) and then concatenate the result in a final segment classification column.  Please see attached file with example.
Example2.xlsx
0
 

Author Comment

by:hkgal
ID: 38767232
will formula like sumproduct, match helps?
0
 
LVL 18

Accepted Solution

by:
xtermie earned 500 total points
ID: 38767272
sumproduct is a calculating function that multiplies corresponding components in the given arrays, and returns the sum of those products - dont think that it can be applied in your case.

Match is a lookup function that searches for a value in an array and returns the relative position of that item - dont think that it can be easily or very efficiently applied in your case.

Doesn't the provided formulas in the example file work for you?
You can hide the two columns if they are in the way :)
Sometimes it is better to break up the formula into two instead of creating very complex formulas and try to see the logic behind what you are trying to do.
Let me know if you have any other ideas so that I can try to help you out.
0
 

Author Closing Comment

by:hkgal
ID: 38767337
Your comment helps!
0

Featured Post

Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Office 2016 without internet 6 37
Excel VBA User Form Help 21 28
Excel - DATEDIF error #NUM 6 19
Return Column Number based on a specific value 25 23
Introduction This Article briefly covers methods of calculating the NPV and IRR variants in Excel as well as the limitations in calculating and interpreting IRR results. Paraphrasing Richard Shockley, author of my favourite finance reference tex…
This article will guide you to convert a grid from a picture into Excel format using Microsoft OneNote and no other 3rd party application.
The viewer will learn how to create a normally distributed random variable in Excel, use a normal distribution to simulate the return on an investment over a period of years, Create a Monte Carlo simulation using a normal random variable, and calcul…
This Micro Tutorial demonstrates in Microsoft Excel how to consolidate your marketing data by creating an interactive charts using form controls. This creates cool drop-downs for viewers of your chart to choose from.

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question