Categorizing an excel column

A

Anna

I have an excel spreadsheet. In column A, is a list of 15,000 phrases
consisting of 5-7 words.

Last night, I was going to go through each phrase in the list, look for
keywords and if it contained it, I would enter the keywords in the adjoining
columns. This would be quite tedious.

Is there any simple way for me to categorize this list using macros or some
third party addon.

As an example, lets say I wanted to to categorize the list based on race,
religion, sex, and country of origin. I would enter specific criteria in
the macro such as race could equal white, black, asian, indian, religion
could equal christian, jewish, muslim, sex could be m or f and country of
origin could be America, or Europe.

The macro would look for these specific words in each of the phrases and if
the phrase contained those keywords, it would tag that phrase by putting the
keyword in the adjoining columns.

The end result would be as follows:

One phrase would be White Christian male teacher. Using the above example,

Column B next to this phrase would contain white
Column C next to this phrase would contain christian
Column D next to this phrase would contain male
Column D next to this phrase would remain blank as it doesn't have any
criteria defined in the macro

Thank you in advance for any help provided.

Jason
 
S

ScottO

Here's one way ...
Assuming that all your phrases are in Column A starting at Row2, and
your various keywords are in B1, C1, D1, etc.
Then put this formula into B2, then copy it across Row 2 as far as
you need, and down as many rows as you need.

=IF(ISERROR(FIND(B$1,$A2)),"",B$1)

Then whenever you chamnge the Keywords across Row 1, the results will
recalculate.

Hope this suits your needs,
Rgds,
ScottO


| I have an excel spreadsheet. In column A, is a list of 15,000
phrases
| consisting of 5-7 words.
|
| Last night, I was going to go through each phrase in the list, look
for
| keywords and if it contained it, I would enter the keywords in the
adjoining
| columns. This would be quite tedious.
|
| Is there any simple way for me to categorize this list using macros
or some
| third party addon.
|
| As an example, lets say I wanted to to categorize the list based on
race,
| religion, sex, and country of origin. I would enter specific
criteria in
| the macro such as race could equal white, black, asian, indian,
religion
| could equal christian, jewish, muslim, sex could be m or f and
country of
| origin could be America, or Europe.
|
| The macro would look for these specific words in each of the
phrases and if
| the phrase contained those keywords, it would tag that phrase by
putting the
| keyword in the adjoining columns.
|
| The end result would be as follows:
|
| One phrase would be White Christian male teacher. Using the above
example,
|
| Column B next to this phrase would contain white
| Column C next to this phrase would contain christian
| Column D next to this phrase would contain male
| Column D next to this phrase would remain blank as it doesn't have
any
| criteria defined in the macro
|
| Thank you in advance for any help provided.
|
| Jason
|
|
|
 
A

Anna

Thank you for your tip, that worked really well. I do appreciate your
assitance in making my job much easier
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top