experian-data-dictionary 1.4.4 → 1.4.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.rubocop.yml +28 -0
- data/Gemfile +3 -3
- data/Rakefile +7 -13
- data/experian_data_dictionary.gemspec +4 -4
- data/lib/element_numbers/0000/en_0000.rb +3 -3
- data/lib/element_numbers/0100/en_0100.rb +12 -12
- data/lib/element_numbers/0100/en_0103.rb +3 -2
- data/lib/element_numbers/0100/en_0107.rb +4 -3
- data/lib/element_numbers/0100/en_0108.rb +22 -11
- data/lib/element_numbers/0100/en_0110.rb +3 -2
- data/lib/element_numbers/0100/en_0112.rb +3 -2
- data/lib/element_numbers/0100/en_0113.rb +3 -2
- data/lib/element_numbers/0100/en_0118.rb +3 -2
- data/lib/element_numbers/0100/en_0119.rb +4 -4
- data/lib/element_numbers/0100/en_0130.rb +3 -2
- data/lib/element_numbers/0100/en_0131.rb +3 -2
- data/lib/element_numbers/0100/en_0132.rb +9 -7
- data/lib/element_numbers/0100/en_0133.rb +3 -2
- data/lib/element_numbers/0100/en_0134.rb +5 -5
- data/lib/element_numbers/0100/en_0135.rb +5 -5
- data/lib/element_numbers/0100/en_0136.rb +5 -5
- data/lib/element_numbers/0100/en_0137.rb +5 -5
- data/lib/element_numbers/0100/en_0138.rb +5 -5
- data/lib/element_numbers/0100/en_0139.rb +5 -5
- data/lib/element_numbers/0100/en_0140.rb +5 -5
- data/lib/element_numbers/0100/en_0141.rb +5 -5
- data/lib/element_numbers/0100/en_0155.rb +3 -3
- data/lib/element_numbers/0100/en_0156.rb +3 -3
- data/lib/element_numbers/0100/en_0160.rb +4 -5
- data/lib/element_numbers/0100/en_0161.rb +4 -5
- data/lib/element_numbers/0100/en_0162.rb +4 -4
- data/lib/element_numbers/0100/en_0164.rb +3 -3
- data/lib/element_numbers/0100/en_0174.rb +3 -3
- data/lib/element_numbers/0100/en_0177.rb +3 -3
- data/lib/element_numbers/0600/en_0601.rb +4 -3
- data/lib/element_numbers/0700/en_0711.rb +4 -4
- data/lib/element_numbers/0700/en_0715.rb +4 -5
- data/lib/element_numbers/0700/en_0716.rb +4 -4
- data/lib/element_numbers/0700/en_0717.rb +4 -4
- data/lib/element_numbers/300/en_310M.rb +3 -3
- data/lib/element_numbers/300/en_313HH.rb +0 -2
- data/lib/element_numbers/8000/en_8102.rb +3 -2
- data/lib/element_numbers/8000/en_8103.rb +3 -2
- data/lib/element_numbers/8000/en_8109.rb +3 -2
- data/lib/element_numbers/8000/en_8123.rb +3 -2
- data/lib/element_numbers/8000/en_8128.rb +3 -2
- data/lib/element_numbers/8000/en_8133.rb +3 -2
- data/lib/element_numbers/8000/en_8136.rb +3 -2
- data/lib/element_numbers/8000/en_8137.rb +3 -2
- data/lib/element_numbers/8000/en_8180.rb +3 -2
- data/lib/element_numbers/8000/en_8181.rb +3 -2
- data/lib/element_numbers/8000/en_8502.rb +8 -6
- data/lib/element_numbers/8000/en_8503.rb +8 -6
- data/lib/element_numbers/8000/en_8504.rb +8 -6
- data/lib/element_numbers/8000/en_8505.rb +8 -6
- data/lib/element_numbers/8000/en_8509.rb +8 -6
- data/lib/element_numbers/8000/en_8519.rb +8 -6
- data/lib/element_numbers/8000/en_8523.rb +8 -6
- data/lib/element_numbers/8000/en_8525.rb +8 -6
- data/lib/element_numbers/8000/en_8526.rb +9 -7
- data/lib/element_numbers/8000/en_8528.rb +8 -6
- data/lib/element_numbers/8000/en_8531.rb +8 -6
- data/lib/element_numbers/8000/en_8532.rb +8 -6
- data/lib/element_numbers/8000/en_8533.rb +10 -9
- data/lib/element_numbers/8000/en_8536.rb +8 -6
- data/lib/element_numbers/8000/en_8537.rb +8 -6
- data/lib/element_numbers/8000/en_8538.rb +8 -6
- data/lib/element_numbers/8000/en_8574.rb +8 -6
- data/lib/element_numbers/8000/en_8580.rb +8 -6
- data/lib/element_numbers/8000/en_8581.rb +8 -6
- data/lib/element_numbers/A/en_A107.rb +3 -2
- data/lib/element_numbers/B/en_B000.rb +5 -5
- data/lib/element_numbers/B/en_B2185.rb +3 -2
- data/lib/element_numbers/B/en_B3010.rb +3 -2
- data/lib/element_numbers/B/en_B3076.rb +3 -2
- data/lib/element_numbers/B/en_B3080.rb +3 -2
- data/lib/element_numbers/B/en_B3081.rb +3 -2
- data/lib/element_numbers/B/en_B3200.rb +3 -2
- data/lib/element_numbers/B/en_B3225.rb +3 -2
- data/lib/element_numbers/B/en_B3226.rb +3 -2
- data/lib/element_numbers/B/en_B3227.rb +3 -2
- data/lib/element_numbers/B/en_B3251.rb +3 -2
- data/lib/element_numbers/B/en_B5011.rb +3 -2
- data/lib/element_numbers/B/en_B5013.rb +3 -2
- data/lib/element_numbers/B/en_B5014.rb +3 -2
- data/lib/element_numbers/B/en_B5016.rb +3 -2
- data/lib/element_numbers/D/en_D105N.rb +3 -3
- data/lib/element_numbers/D/en_D105S.rb +3 -2
- data/lib/element_numbers/D/en_D200.rb +3 -3
- data/lib/element_numbers/F/en_F031.rb +3 -3
- data/lib/element_numbers/G/en_G2001.rb +5 -5
- data/lib/element_numbers/G/en_G2514.rb +3 -3
- data/lib/element_numbers/G/en_G2516.rb +3 -3
- data/lib/element_numbers/G/en_G2601.rb +3 -3
- data/lib/element_numbers/G/en_G2602.rb +3 -3
- data/lib/element_numbers/G/en_G2603.rb +3 -3
- data/lib/element_numbers/G/en_GEO6.rb +3 -3
- data/lib/element_numbers/L/en_L000.rb +4 -4
- data/lib/element_numbers/P/en_P213E.rb +4 -4
- data/lib/element_numbers/P/en_P213H.rb +21 -21
- data/lib/element_numbers/P/en_P213W.rb +4 -4
- data/lib/element_numbers/P/en_P400.rb +6 -4
- data/lib/element_numbers/T/en_T2000.rb +4 -4
- data/lib/element_numbers/V/en_V000.rb +3 -3
- data/lib/element_numbers/Y/en_Y000.rb +3 -3
- data/lib/experian.rb +10 -10
- data/spec/functional/0000/en_0000_spec.rb +13 -16
- data/spec/functional/0100/en_0100_spec.rb +13 -20
- data/spec/functional/0100/en_0103_spec.rb +9 -12
- data/spec/functional/0100/en_0107_spec.rb +10 -13
- data/spec/functional/0100/en_0108_spec.rb +411 -445
- data/spec/functional/0100/en_0110_spec.rb +11 -14
- data/spec/functional/0100/en_0112_spec.rb +7 -10
- data/spec/functional/0100/en_0113_spec.rb +12 -16
- data/spec/functional/0100/en_0118_spec.rb +11 -15
- data/spec/functional/0100/en_0119_spec.rb +7 -10
- data/spec/functional/0100/en_0130_spec.rb +8 -12
- data/spec/functional/0100/en_0131_spec.rb +9 -13
- data/spec/functional/0100/en_0132_spec.rb +4 -8
- data/spec/functional/0100/en_0133_spec.rb +4 -8
- data/spec/functional/0100/en_0134_spec.rb +15 -19
- data/spec/functional/0100/en_0135_spec.rb +15 -19
- data/spec/functional/0100/en_0136_spec.rb +15 -19
- data/spec/functional/0100/en_0137_spec.rb +14 -18
- data/spec/functional/0100/en_0138_spec.rb +14 -18
- data/spec/functional/0100/en_0139_spec.rb +14 -18
- data/spec/functional/0100/en_0140_spec.rb +14 -18
- data/spec/functional/0100/en_0141_spec.rb +14 -18
- data/spec/functional/0100/en_0155_spec.rb +7 -11
- data/spec/functional/0100/en_0156_spec.rb +7 -11
- data/spec/functional/0100/en_0160_spec.rb +8 -13
- data/spec/functional/0100/en_0161_spec.rb +8 -12
- data/spec/functional/0100/en_0162_spec.rb +7 -11
- data/spec/functional/0100/en_0164_spec.rb +9 -14
- data/spec/functional/0100/en_0174_spec.rb +8 -13
- data/spec/functional/0100/en_0177_spec.rb +7 -12
- data/spec/functional/0600/en_0601_spec.rb +7 -12
- data/spec/functional/0700/en_0711_spec.rb +10 -13
- data/spec/functional/0700/en_0715_spec.rb +11 -15
- data/spec/functional/0700/en_0716_spec.rb +11 -15
- data/spec/functional/0700/en_0717_spec.rb +11 -12
- data/spec/functional/300/en_310M_spec.rb +66 -70
- data/spec/functional/300/en_313HH_spec.rb +7 -12
- data/spec/functional/8000/en_8102_spec.rb +7 -10
- data/spec/functional/8000/en_8103_spec.rb +7 -10
- data/spec/functional/8000/en_8109_spec.rb +7 -10
- data/spec/functional/8000/en_8123_spec.rb +7 -10
- data/spec/functional/8000/en_8128_spec.rb +7 -10
- data/spec/functional/8000/en_8133_spec.rb +7 -10
- data/spec/functional/8000/en_8136_spec.rb +7 -10
- data/spec/functional/8000/en_8137_spec.rb +7 -10
- data/spec/functional/8000/en_8180_spec.rb +7 -10
- data/spec/functional/8000/en_8181_spec.rb +7 -10
- data/spec/functional/8000/en_8502_spec.rb +10 -13
- data/spec/functional/8000/en_8503_spec.rb +10 -13
- data/spec/functional/8000/en_8504_spec.rb +10 -13
- data/spec/functional/8000/en_8505_spec.rb +10 -13
- data/spec/functional/8000/en_8509_spec.rb +7 -10
- data/spec/functional/8000/en_8519_spec.rb +10 -13
- data/spec/functional/8000/en_8523_spec.rb +7 -10
- data/spec/functional/8000/en_8525_spec.rb +10 -13
- data/spec/functional/8000/en_8526_spec.rb +10 -13
- data/spec/functional/8000/en_8536_spec.rb +7 -10
- data/spec/functional/8000/en_8537_spec.rb +7 -10
- data/spec/functional/8000/en_8580_spec.rb +7 -10
- data/spec/functional/8000/en_8581_spec.rb +7 -10
- data/spec/functional/A/en_A107_spec.rb +9 -14
- data/spec/functional/B/en_B2185_spec.rb +7 -9
- data/spec/functional/B/en_B3010_spec.rb +7 -9
- data/spec/functional/B/en_B3076_spec.rb +7 -10
- data/spec/functional/B/en_B3080_spec.rb +7 -10
- data/spec/functional/B/en_B3081_spec.rb +7 -10
- data/spec/functional/B/en_B3200_spec.rb +7 -10
- data/spec/functional/B/en_B3225_spec.rb +7 -10
- data/spec/functional/B/en_B3226_spec.rb +7 -10
- data/spec/functional/B/en_B3227_spec.rb +7 -10
- data/spec/functional/B/en_B3251_spec.rb +7 -10
- data/spec/functional/B/en_B5011_spec.rb +7 -9
- data/spec/functional/B/en_B5013_spec.rb +7 -9
- data/spec/functional/B/en_B5014_spec.rb +7 -9
- data/spec/functional/B/en_B5016_spec.rb +7 -9
- data/spec/functional/D/en_D105N_spec.rb +16 -19
- data/spec/functional/D/en_D200_spec.rb +7 -10
- data/spec/functional/F/en_F031_spec.rb +11 -15
- data/spec/functional/G/en_G2001_spec.rb +8 -9
- data/spec/functional/G/en_G2514_spec.rb +9 -11
- data/spec/functional/G/en_G2516_spec.rb +9 -11
- data/spec/functional/G/en_G2602_spec.rb +8 -9
- data/spec/functional/G/en_G2603_spec.rb +10 -11
- data/spec/functional/L/en_L000_spec.rb +1 -1
- data/spec/functional/P/en_P213E_spec.rb +8 -11
- data/spec/functional/P/en_P213H_spec.rb +8 -11
- data/spec/functional/P/en_P213W_spec.rb +8 -11
- data/spec/functional/P/en_P400_spec.rb +5 -8
- data/spec/functional/T/en_T2000_spec.rb +9 -14
- data/spec/functional/V/en_V000_spec.rb +8 -10
- data/spec/functional/Y/en_Y000_spec.rb +10 -12
- data/spec/functional/experian_spec.rb +11 -14
- data/spec/spec_helper.rb +2 -2
- metadata +5 -3
@@ -1,12 +1,13 @@
|
|
1
1
|
module Experian
|
2
2
|
class DataDictionary
|
3
|
-
|
4
3
|
# 2000 Geo Mandatory Append
|
5
4
|
def self.en_l000_column_name
|
6
5
|
'2000 Geo Mandatory Append'
|
7
6
|
end
|
8
7
|
|
9
|
-
def self.en_l000_value_description(
|
8
|
+
def self.en_l000_value_description(_key)
|
9
|
+
''
|
10
|
+
end
|
10
11
|
|
11
12
|
def self.en_l000_description
|
12
13
|
'The Geo mandatory append is required when any data from the geo code process (L and K file types) is appended. It consists of a match level and street match level.'
|
@@ -26,10 +27,9 @@ module Experian
|
|
26
27
|
'L' => 'Lat/long not determined on Auxiliary File match'
|
27
28
|
}
|
28
29
|
return 'Input Zip Code did not match the master file.' if key.size == 0
|
29
|
-
return census[key[0]] + ' - Successful match' if key.size == 1
|
30
|
+
return census[key[0]] + ' - Successful match' if key.size == 1 && !census[key[0]].nil?
|
30
31
|
|
31
32
|
[street_match[key[1]], census[key[0]]].join(' - ')
|
32
33
|
end
|
33
|
-
|
34
34
|
end
|
35
35
|
end
|
@@ -1,12 +1,13 @@
|
|
1
1
|
module Experian
|
2
2
|
class DataDictionary
|
3
|
-
|
4
3
|
# Inc Producing Assets IPA V3
|
5
4
|
def self.en_p213e_column_name
|
6
5
|
'Inc Producing Assets IPA V3'
|
7
6
|
end
|
8
7
|
|
9
|
-
def self.en_p213e_value_description(
|
8
|
+
def self.en_p213e_value_description(_key)
|
9
|
+
''
|
10
|
+
end
|
10
11
|
|
11
12
|
def self.en_p213e_description
|
12
13
|
'Income Producing Assets (IPA) is one of the models that are used to derive the P$YCLE Financial Markets. This model specifically tries to predict real worth or asset value of the household. IPA estimates affluence within ten ranges.'
|
@@ -34,9 +35,8 @@ module Experian
|
|
34
35
|
'99' => 'Unknown / Default'
|
35
36
|
}
|
36
37
|
|
37
|
-
return 'Unknown' if key.size != 3
|
38
|
+
return 'Unknown' if key.size != 3 || code[key[0]].nil? || values[key[1..2]].nil?
|
38
39
|
[values[key[1..2]], code[key[0]]].join(' - ')
|
39
40
|
end
|
40
|
-
|
41
41
|
end
|
42
42
|
end
|
@@ -1,12 +1,13 @@
|
|
1
1
|
module Experian
|
2
2
|
class DataDictionary
|
3
|
-
|
4
3
|
# Psycle HH V3
|
5
4
|
def self.en_p213h_column_name
|
6
5
|
'Psycle HH V3'
|
7
6
|
end
|
8
7
|
|
9
|
-
def self.en_p213h_value_description(
|
8
|
+
def self.en_p213h_value_description(_key)
|
9
|
+
''
|
10
|
+
end
|
10
11
|
|
11
12
|
def self.en_p213h_description
|
12
13
|
'P$YCLE NE is a household-level segmentation system which assists marketers to predict financial behavior.'
|
@@ -22,26 +23,26 @@ module Experian
|
|
22
23
|
values = {
|
23
24
|
'01' => 'The Wealth Market - Wealthy Older Mostly w/o Kids When it comes to American affluence, The Wealth Market is home to the richest addresses in the nation. Consisting of older suburban couples, this is where to find millionaires in the P$YCLE system. Most of the households boast more than $1 million in income-producing assets, and invest in a broad range of stocks, corporate/municipal bonds, mutual funds, and real estate. These consumers also excel in buying annuities and other investment-style life insurance products. In The Wealth Market, residents are known for both making money and spending money in grand style, splurging on foreign travel and cultural events as well as hiring a small army of financial managers, estate planners, and full-service brokers the better to accumulate more assets.',
|
24
25
|
'02' => "Globetrotters - Upper Mid Mature Mostly w/o Kids Members of Globetrotters have reached an age over 65 years old and a level of financial comfort many have six-figure incomes that allow them to indulge their passion for foreign travel. Consisting mostly of suburban couples, households in this segment have amassed substantial IPA, such as variable-rate annuities, government securities, and corporate/municipal bonds. Admittedly risk-averse in their financial behavior, they buy a variety of insurance products, including long-term care, medical, and residential coverage. But playing it safe doesn't apply when it comes to exploring other countries; members of Globetrotters have been known to take more than three foreign trips a year. And many get their news about world events from US News & World Report and Condé Nast Traveler.",
|
25
|
-
'03' =>
|
26
|
-
'04' =>
|
27
|
-
'05' =>
|
26
|
+
'03' => 'Business Class - Wealthy Older Mostly w/o Kids As the segment most likely to belong to a country club, Business Class is known for its lavish spending style. But many of its fifty-something executive couples have begun to divert their high incomes to build up long- neglected nest eggs. Segment households rank at the top for having Keogh plans, cash management accounts, and unit investment trusts. But they have only one-third the level of income-producing assets of The Wealth Market, and many are trying to make up for lost time by aggressively investing in stocks, mutual funds, and investment-style insurance. Located mostly in pricey suburban areas, Business Class scores high for business and pleasure travel, high-end catalog shopping, listening to classical radio, and reading business publications.',
|
27
|
+
'04' => 'Golden Agers - Upper Mid Mature Mostly w/o Kids One of the oldest financial segments, Golden Agers is a collection of over-65-year-olds whove amassed substantial levels of IPA. These senior singles and couples, typically living in large suburban homes, tend to be fiscally conservative; they rank at the top for having corporate/municipal bonds, government securities, fixed-rate annuities, and savings accounts. In addition, theyre more than twice as likely as average Americans to own multiple annuities and long-term care insurance. Enjoying their cushy retirements, they fill their days with golf (both playing and watching), the arts, and public TV and radio. Like many affluent seniors, they leave their investment decisions to brokers at full-service brokerage firms.',
|
28
|
+
'05' => 'Power Couples - Wealthy Older w/o Kids The most affluent Younger Years segment, Power Couples seems to have it made: six-figure incomes, designer-decorated houses, and high balances in their income-producing assets. As investors, these mostly 45- to 54-year-old couples boast retirement accounts containing a welldiversified mix of options, stocks, and mutual funds. Typically college-educated and holding management jobs, they also tend to be cultured consumers who travel the world, subscribe to publications like Forbes and Architectural Digest, and shop at swanky stores like Lord & Taylor and Nordstrom. When it comes to managing their money, however, they put their faith in the pros, exhibiting high rates for using asset managers, estate planners, and full-service brokers. Internet savvy, they track how well their investments are doing online.',
|
28
29
|
'06' => "Civic Spirits - Midscale Mature Mostly w/o Kids They may be retired, but they're not retiring. The over-65-year-old couples who make up Civic Spirits tend to be community activists who participate in civic events, write newspaper editors, and contact elected officials at high rates. Their financial behavior is less adventurous, with households preferring investments like CDs, corporate/municipal bonds, government securities, and annuities, particularly those purchased for tax shelters. Civic Spirits members also rank high for buying long-term care insurance and residential insurance for their condos. When they're not volunteering, these Americans keep up with their civic interests by watching news programs on television, tuning in to news/talk radio stations, and reading mature market magazines.",
|
29
|
-
'07' =>
|
30
|
-
'08' =>
|
31
|
-
'09' =>
|
32
|
-
'10' =>
|
33
|
-
'11' =>
|
30
|
+
'07' => 'Family Fortunes - Wealthy Middle Age w/Kids The members of Family Fortunes rank at the top in many financial categories: investing in futures and options, owning mutual funds and U.S. Savings Bonds, and acquiring first mortgages worth over $150,000. They need to: these 35- to 54-year-old suburbanites have more children than any other P$YCLE segment. With high incomes and expensive homes, they make a prime target for high-value life and homeowners insurance. No segment has more collegeeducated residents, and they enjoy an energetic lifestyle: traveling around the world, shopping at high-end department stores, owning luxury vehicles, and enjoying pricey sports like skiing and tennis. Not surprisingly, their favorite media outlets include business and travel magazines, which they read at the highest rate in the nation.',
|
31
|
+
'08' => 'Domestic Bliss - Wealthy Older Family Mix Domestic Bliss is home to fashionable couples in their peak earning years. Consisting mostly of adults between the ages of 45 and 64, the White, Black, and Asian households in this segment report six-figure incomes and income-producing assets of over $100,000. Generally college graduates, they work in management, own their home, and hold extensive investments in stocks,mutual funds, bonds, and real estate. They have solid credit profiles and typically have second mortgages, home equity loans, and personal lines of credit, not to mention auto, term life, longterm care, and investment-style insurance policies. Active and cultured, Domestic Bliss members travel abroad, attend the theater, and enjoy tennis, golf, and skiing. With their sizable portfolios, they have high rates for using full-service brokers and estate planning services.',
|
32
|
+
'09' => 'Big Spenders - Wealthy Middle Age Mostly w/ Kids The suburban Boomers who comprise Big Spenders are the ultimate financial jugglers. With teenagers at home and retirement looming, theyve managed to craft both enviable lifestyles and fat portfolios filled with stock options, mutual funds, securities, and bonds. Higher than average incomes help, but they also rank at the top for using home equity lines of credit and second mortgages. Big Spenders represents an attractive market for a range of insurance products: term life, auto, disability and long-term care coverage. But these dual-income households know how to enjoy their money: theyre twice as likely as average Americans to drive new cars, frequent casual dining restaurants, build basement gyms, and take frequent trips around the world. Their top-rated mediaairline magazinesserves as a guide to worldly living.',
|
33
|
+
'10' => 'Capital Accumulators - Upper Mid Older Mostly w/o Kids Capital Accumulators is a collection of 55+ year-old suburbanites dedicated to growing their IRAs and 401(k) retirement accounts. Theyre twice as likely as average Americans to own securities, mutual funds, and real estate investments. Many households are home to white-collar professionals who have parlayed upper middle class incomes into substantial income-producing assets. They tend to lead very active lifestyles, traveling abroad, skiing at exclusive resorts, and paying for investment advice from stockbrokers and financial planners. With their brains and bucks, Capital Accumulators consume a variety of media, reading the Wall Street Journal and Cigar Aficionado, and watching pay-per-view movies at high rates.',
|
34
|
+
'11' => 'Savvy Savers - Lower Mid Mature Mostly w/o Kids The living is easy in Savvy Savers, a segment of well-invested retirees scattered across the nations suburban and exurban communities. These cautious investors rank near the top for owning CDs, money market funds, municipal bonds, and fixed- and variable-rate annuities. Together, these assets provide them sizable nest eggs, though they pursue only midscale lifestyles, characterized by watching golf on TV and socializing at the fraternal order. These are the folks who take full advantage of senior discounts and are coupon users at drugstores, grocery stores, movie theaters, and restaurants. When they go on vacation, theyre typically value-oriented travelers who drive to a domestic destination and stay at a Comfort Inn.',
|
34
35
|
'12' => "Feathered Nests - Wealthy Middle Age Family Mix There's money tucked away in Feathered Nests, a collection of middle-aged families with high incomes and above-average investable assets. A mix of college-educated Whites and Asians,these 35- to 54-year-olds typically hold management jobs and have begun filling their retirement accounts with mutual funds, stocks, bonds, and CDs. They're also a trong credit market, often carrying jumbo mortgages and home equity lines of credit. Insurance omnivores, they own annuities, term and whole life, disability coverage, and auto insurance for their multiple cars. And they enjoy good-life pursuits, like golfing and sailing, boutique shopping for children's toys and collectibles, and tuning their high-end TVs to ice hockey matches and public roadcasting programs. For investment tips, they read a variety of business magazines.",
|
35
|
-
'13' =>
|
36
|
-
'14' =>
|
36
|
+
'13' => 'Annuity-ville - Lower Mid Mature Mostly w/o Kids No place has more seniors, fewer children, and a greater passion for fixed-rate annuities than Annuity-ville. These upper-middle-class suburbanites living in established communities score near the top for staid investments like government securities, CDs,and money market funds. Many members are preoccupied with preserving their wealth, and they boast high rates for having tax shelters, unit investment trusts, and cash management accounts. But theyre also willing to spend their money shopping at upscale department stores and donating to PBS. Leading somewhat sedentary lifestyles, they enjoy tuning in to news, old movies, and sports such as golf and tennis on TV.',
|
37
|
+
'14' => 'Financial Independents - Upscale Older Mostly w/o Kids The members of Financial Independents like to go it alone. Upscale Boomers living in suburbia, they trade online, read self-help business books, and find investment ideas in The Wall Street Journal. But their investment style leans towards safety, with segment members preferring to fill their IRAs with mutual funds and money market accounts at high rates. And they offer only a middling market for insurance products, with high indices only for disability insurance, variable-rate annuities, and high-value homeowners insurance policies. Married and mostly without children at home, these professional couples have pleasant lifestyles, traveling often, shopping at warehouse clubs, and surfing the web. Their entertainment tastes reflect their inquisitive minds: talk and all-news radio, jazz and classical music, and travel and epicurean magazines.',
|
37
38
|
'15' => "Midlife Highlife - Wealthy Younger Mostly w/ Kids Big homes, diversified retirement accounts and high-value life insurance that's the skinny on Midlife Highlife. This upscale segment is filled with investment-savvy, 25- to 44-year-old Whites and Asians who own mutual funds, stocks, stock options, and savings bonds at high rates. With their college degrees and white-collar jobs, they typically have high incomes and above-average investable assets. But because many are married and raising young children, they also score high for acquiring term life, disability, and long-term care insurance to protect their growing families. Active and sophisticated, Midlife Highlife members enjoy attending museums and dance performances, as well as going biking, backpacking, and jogging. They're also fans of the virtual world, where they buy books, trade stocks, and acquire mutual funds. 16 = Leisure Land - Lower Mid Mature Mostly w/o Kids Located in a mix of suburban and exurban communities, Leisure Land residents have below average to moderate portfolios and lower midscale incomes. These households of over",
|
38
|
-
'16' =>
|
39
|
-
'17' =>
|
40
|
-
'18' =>
|
41
|
-
'19' =>
|
42
|
-
'20' =>
|
43
|
-
'21' =>
|
44
|
-
'22' =>
|
39
|
+
'16' => 'Leisure Land - Lower Mid Mature Mostly w/o Kids Located in a mix of suburban and exurban communities, Leisure Land residents have below average to moderate portfolios and lower midscale incomes. These households of over-65-year-old couples, widows, and divorcees have average educations, and home values. But theyve managed to sock away enough money to create solid investment portfoliosalbeit characterized by a conservative assortment of annuities, CDs, money market accounts, and mutual funds. As a result, they can afford to spend their time socializing at fraternal orders, and taking the occasional all-inclusive-package vacation. At home, members of Leisure Land also rank high for watching television, especially talk shows, cultural programs, and, befitting their aspirations, Who Wants to be a Millionaire?',
|
40
|
+
'17' => 'Home Sweet Equity -Upscale Older Mostly w/o Kids Upscale incomes, above average assets, and home-owning couples make this segment an attractive market for large-balance credit products. In Home Sweet Equity, many of the 45- to 64-year-old residents are tapping the value of their older homes with home equity loans, second mortgages, and home improvement loans. With well-paying white-collar jobs, these traditionalists rank high for buying fixed-rate annuities and using credit unions and savings and loan associations. Their above- average presence in exurban areas also helps explain their fondness for hunting, power boating, and buying from mail-order catalogs. Given their busy schedules, they get what information they can about life, medical, and mortgage insurance from newspaper ads and TV and radio commercialsespecially oldies radio stations.',
|
41
|
+
'18' => 'Travel & Antiques - Travel & Antiques comes by its name honestly: The members of this segment love both traveling and collecting, especially antiques and coins. Mostly empty-nesting couples between 55 and 64 years old, these households have filled their IRAs with a range of investments: stocks, mutual funds, CDs and money market accounts. They qualify for personal and home equity loans, and likely use them for home renovation projects. Residents of Travel & Antiques have high rates for traveling in the U.S. and abroad, favoring excursions to Britain and car trips across America. And when theyÆve returned to their suburban homes, they often take armchair journeys, reading travel magazines, watching the Travel Channel and rarely missing an installment of The Antiques Roadshow.',
|
42
|
+
'19' => 'New Money Upscale - Middle Age Family Mix Middle age, upscale suburban and town families make up New Money, a segment of mostly thirty and forty-something households who invest heavily in stocks, futures, and mutual funds. With their college degrees and management careers, these dual-income upscale households have above average levels of income-producing assets. They also make for financially savvy consumers, trading stocks online, using credit cards with rewards programs, and getting financial ideas from investment magazines and websites. In addition to staying financially fit, New Money members also try to stay physically healthy, pursuing aerobic sports such as skiing, bicycling, and in-line skating. And they work to protect their dependents from undue financial burdens with lots of high-balance term and whole life insurance.',
|
43
|
+
'20' => 'Comfortably Retired - Lower Mid Mature Mostly w/o Kids The members of Comfortably Retired could be poster children for living below ones means. Despite their lower-middle class incomes, these over-65 singles and couples have solid net worthmostly due to their homes. Their small investments include a well-diversified mix of conservative fixed-rate annuities, variable-rate annuities, and unit investment trusts. Together, these investments provide Comfortably Retired households with tranquil lifestyles. With a disproportionate number of residents living in exurban areas, many households enjoy pursuits such as bird watching, socializing at church, and watching TV, especially cultural and game shows. In Comfortably Retired, big-time excitement means Bingo Night.',
|
44
|
+
'21' => 'Leveraged Life - Upper Mid Older Family Mix They may be upper-middle-class, but Leveraged Life members often maintain that status by living on credit. These older homeowners index high for having second mortgages, using home equity lines of credit, and maxing out the rewards on their charge cards. Typically having attended at least some college, they tend to earn upper midscale paychecks from white-collar jobsand carry death and disability insurance to protect them. But this group has only modest assets in conservative investments like U.S. savings bonds and Treasury bills. Fond of the outdoors, many enjoy skiing, camping, whitewater rafting, and hunting. Media-wise, members of this group enjoy watching country music TV, reading fishing and hunting magazines, and listening to classic rock radio.',
|
45
|
+
'22' => 'Bargain Lovers = Upper Mid Middle Age w/o Kids Call them thrifty or call them economical; just dont call them cheap. The members of Bargain Lovers have upper middle class incomes and moderate levels of income-producing assets, but they still love a dealwhether its buying stocks through discount brokers or cashing in credit card rewards for free airline tickets. A mix of under 55 year-old singles and couples, these urban and suburban households are heavy users of mortgage products, high-end credit cards, and auto leases. They also fill their Roth IRAs and 401(k)s with mutual funds, stocks, and money market funds. Internet fans, they go online to bank, comparison shop, get travel information, and trade stocks. Their media tastes are also progressive: they enjoy new age music and soft rock as well as computer and sports magazines.',
|
45
46
|
'23' => "School Daze - Upper Mid Middle Age w/ Kids
|
46
47
|
A collection of large, suburban households, School Daze represents one of the nations best markets for borrowing. These upper-middle-class families score near the top for having first mortgages, home
|
47
48
|
improvement loans, and auto loans. Yet these Gen-X parents have only begun to think about retirement, and theyve acquired only moderate levels of income-producing assets such as stocks and mutual funds.
|
@@ -260,9 +261,8 @@ that members of Bottom-Line Blues have modest ifestyles, spending their leisure
|
|
260
261
|
oriented media, including BET, urban
|
261
262
|
contemporary radio, and magazines like Jet, Essence, and Ebony."
|
262
263
|
}
|
263
|
-
return 'Unknown' if key.size != 3
|
264
|
+
return 'Unknown' if key.size != 3 || code[key[0]].nil? || values[key[1..2]].nil?
|
264
265
|
[values[key[1..2]], code[key[0]]].join(' - ')
|
265
266
|
end
|
266
|
-
|
267
267
|
end
|
268
268
|
end
|
@@ -1,12 +1,13 @@
|
|
1
1
|
module Experian
|
2
2
|
class DataDictionary
|
3
|
-
|
4
3
|
# Net Worth V3
|
5
4
|
def self.en_p213w_column_name
|
6
5
|
'Net Worth V3'
|
7
6
|
end
|
8
7
|
|
9
|
-
def self.en_p213w_value_description(
|
8
|
+
def self.en_p213w_value_description(_key)
|
9
|
+
''
|
10
|
+
end
|
10
11
|
|
11
12
|
def self.en_p213w_description
|
12
13
|
'Net Worth is defined as a household\'s total financial assets minus its liabilities. Assets include financial holdings such as deposit accounts, investments and home value. Liabilities include loans, mortgages and credit card debt.'
|
@@ -33,9 +34,8 @@ module Experian
|
|
33
34
|
'99' => 'Unknown / Default'
|
34
35
|
}
|
35
36
|
|
36
|
-
return 'Unknown' if key.size != 3
|
37
|
+
return 'Unknown' if key.size != 3 || code[key[0]].nil? || values[key[1..2]].nil?
|
37
38
|
[values[key[1..2]], code[key[0]]].join(' - ')
|
38
39
|
end
|
39
|
-
|
40
40
|
end
|
41
41
|
end
|
@@ -1,12 +1,13 @@
|
|
1
1
|
module Experian
|
2
2
|
class DataDictionary
|
3
|
-
|
4
3
|
# GreenAware
|
5
4
|
def self.en_p400_column_name
|
6
5
|
'GreenAware'
|
7
6
|
end
|
8
7
|
|
9
|
-
def self.en_p400_value_description(
|
8
|
+
def self.en_p400_value_description(_key)
|
9
|
+
''
|
10
|
+
end
|
10
11
|
|
11
12
|
def self.en_p400_description
|
12
13
|
'GreenAware Segmentation targeting system includes attitudes, opinions, lifestyle, buying behavior, and media usage. Based on the distinctive mindset of consumers towards the environment, we can better
|
@@ -23,7 +24,9 @@ understand four distinct consumer segments:
|
|
23
24
|
'GreenAware Tiers'
|
24
25
|
end
|
25
26
|
|
26
|
-
def self.en_p400a_value_description(
|
27
|
+
def self.en_p400a_value_description(_key)
|
28
|
+
''
|
29
|
+
end
|
27
30
|
|
28
31
|
def self.en_p400a_description
|
29
32
|
'GreenAware Segmentation targeting system includes attitudes, opinions, lifestyle, buying behavior, and media usage based on the distinctive mindset of consumers toward the Environment. GreenAware Tiers offers
|
@@ -54,6 +57,5 @@ campaign effectiveness.'
|
|
54
57
|
}
|
55
58
|
key.empty? ? 'Unknown' : values[key]
|
56
59
|
end
|
57
|
-
|
58
60
|
end
|
59
61
|
end
|
@@ -1,12 +1,13 @@
|
|
1
1
|
module Experian
|
2
2
|
class DataDictionary
|
3
|
-
|
4
3
|
# Discretionary Spend Estimate
|
5
4
|
def self.en_t2000_column_name
|
6
5
|
'Discretionary Spend Estimate'
|
7
6
|
end
|
8
7
|
|
9
|
-
def self.en_t2000_value_description(
|
8
|
+
def self.en_t2000_value_description(_key)
|
9
|
+
''
|
10
|
+
end
|
10
11
|
|
11
12
|
def self.en_t2000_description
|
12
13
|
'Discretionary Spend Estimate predicts the dollar estimate of annual spend on non-essential, discretionary expenses such as household furniture, alcohol and tobacco, donations, dining out, education, reading, personal care and entertainment (fees, audio/visual equipment, toys, hobbies, pets, playground equipment and other equipment). Represents an actual dollar amount.'
|
@@ -18,9 +19,8 @@ module Experian
|
|
18
19
|
'L' => 'Living unit level data',
|
19
20
|
'Z' => 'Zip level data'
|
20
21
|
}
|
21
|
-
return 'Unknown' if key.size != 6
|
22
|
+
return 'Unknown' if key.size != 6 || values[key[0]].nil? || key[1..6].to_i < 888 || key[1..6].to_i > 87_900
|
22
23
|
[values[key[0]], [key[1..6]]].join(' - ')
|
23
24
|
end
|
24
|
-
|
25
25
|
end
|
26
26
|
end
|
@@ -1,12 +1,13 @@
|
|
1
1
|
module Experian
|
2
2
|
class DataDictionary
|
3
|
-
|
4
3
|
# New Median Mandatory Append
|
5
4
|
def self.en_v000_column_name
|
6
5
|
'New Median Mandatory Append'
|
7
6
|
end
|
8
7
|
|
9
|
-
def self.en_v000_value_description(
|
8
|
+
def self.en_v000_value_description(_key)
|
9
|
+
''
|
10
|
+
end
|
10
11
|
|
11
12
|
def self.en_v000_description
|
12
13
|
'The New Median mandatory append is required when any data from the New Median file is appended. It consists of a match level.'
|
@@ -19,6 +20,5 @@ module Experian
|
|
19
20
|
}
|
20
21
|
key.empty? ? 'Non-match' : values[key]
|
21
22
|
end
|
22
|
-
|
23
23
|
end
|
24
24
|
end
|
@@ -1,12 +1,13 @@
|
|
1
1
|
module Experian
|
2
2
|
class DataDictionary
|
3
|
-
|
4
3
|
# Census Demographic Match Level Mandatory Append
|
5
4
|
def self.en_y000_column_name
|
6
5
|
'Census Demographic Match Level Mandatory Append'
|
7
6
|
end
|
8
7
|
|
9
|
-
def self.en_y000_value_description(
|
8
|
+
def self.en_y000_value_description(_key)
|
9
|
+
''
|
10
|
+
end
|
10
11
|
|
11
12
|
def self.en_y000_description
|
12
13
|
'The Census Demographic Match Level mandatory append is required when any 2000 Census demographic data is appended. It consists of a match level.'
|
@@ -21,6 +22,5 @@ module Experian
|
|
21
22
|
}
|
22
23
|
key.empty? ? 'Non-match' : values[key]
|
23
24
|
end
|
24
|
-
|
25
25
|
end
|
26
26
|
end
|
data/lib/experian.rb
CHANGED
@@ -6,22 +6,22 @@ module Experian
|
|
6
6
|
def self.lookup(column, key)
|
7
7
|
column = column.to_s.downcase.gsub(/\s+/, '')
|
8
8
|
key = key.to_s.strip
|
9
|
-
|
9
|
+
send("en_#{column}", key)
|
10
10
|
end
|
11
11
|
|
12
12
|
def self.column_name(column)
|
13
13
|
column = column.to_s.downcase.gsub(/\s+/, '')
|
14
|
-
|
14
|
+
send("en_#{column}_column_name")
|
15
15
|
end
|
16
16
|
|
17
17
|
def self.value_description(column)
|
18
18
|
column = column.to_s.downcase.gsub(/\s+/, '')
|
19
|
-
|
19
|
+
send("en_#{column}_value_description")
|
20
20
|
end
|
21
21
|
|
22
22
|
def self.description(column)
|
23
23
|
column = column.to_s.downcase.gsub(/\s+/, '')
|
24
|
-
|
24
|
+
send("en_#{column}_description")
|
25
25
|
end
|
26
26
|
|
27
27
|
def self.method_missing(method, *args, &block)
|
@@ -30,20 +30,20 @@ module Experian
|
|
30
30
|
column = method_parts[1]
|
31
31
|
if /^[0-9]{1,3}$/ =~ column
|
32
32
|
letters = ''
|
33
|
-
column =
|
34
|
-
#new_method = method_parts.size == 3 ? "en_#{column}_description".to_sym : "en_#{column}".to_sym
|
33
|
+
column = '%04d' % column
|
34
|
+
# new_method = method_parts.size == 3 ? "en_#{column}_description".to_sym : "en_#{column}".to_sym
|
35
35
|
elsif /[a-z]$/ =~ column
|
36
36
|
letters = column.match(/[a-z]+$/)[0]
|
37
|
-
column =
|
38
|
-
#new_method = method_parts.size == 3 ? "en_#{column}#{letters}_description".to_sym : "en_#{column}#{letters}".to_sym
|
37
|
+
column = '%04d' % column.to_i
|
38
|
+
# new_method = method_parts.size == 3 ? "en_#{column}#{letters}_description".to_sym : "en_#{column}#{letters}".to_sym
|
39
39
|
end
|
40
40
|
|
41
41
|
method_parts.shift(2)
|
42
42
|
method_sufix = method_parts.join('_')
|
43
43
|
new_method = method_sufix.size > 0 ? "en_#{column}#{letters}_#{method_sufix}".to_sym : "en_#{column}#{letters}".to_sym
|
44
44
|
|
45
|
-
if
|
46
|
-
return
|
45
|
+
if methods.include?(new_method)
|
46
|
+
return send(new_method, *args, &block)
|
47
47
|
else
|
48
48
|
super(new_method, *args, &block)
|
49
49
|
end
|
@@ -1,25 +1,22 @@
|
|
1
1
|
require File.join(Dir.pwd, 'spec', 'spec_helper')
|
2
2
|
|
3
3
|
describe 'Experian::DataDictionary 0000' do
|
4
|
-
|
5
4
|
context 'valid lookup' do
|
6
|
-
it { expect(
|
7
|
-
it { expect(
|
8
|
-
it { expect(
|
9
|
-
it { expect(
|
10
|
-
it { expect(
|
11
|
-
it { expect(
|
12
|
-
it { expect(
|
13
|
-
it { expect(
|
14
|
-
it { expect(
|
15
|
-
it { expect(
|
5
|
+
it { expect(Experian::DataDictionary.column_name('0000')).to eq('Enhancement Mandatory Append') }
|
6
|
+
it { expect(Experian::DataDictionary.lookup('0000', 'H')).to eq('Household Match') }
|
7
|
+
it { expect(Experian::DataDictionary.lookup('0000', 'F')).to eq('Household Match') }
|
8
|
+
it { expect(Experian::DataDictionary.lookup('0000', 'P')).to eq('Person Match') }
|
9
|
+
it { expect(Experian::DataDictionary.lookup('0000', 'I')).to eq('Person Match') }
|
10
|
+
it { expect(Experian::DataDictionary.lookup('0000', 'G')).to eq('Geographic or Area Level Match') }
|
11
|
+
it { expect(Experian::DataDictionary.lookup('0000', 'E')).to eq('Geographic or Area Level Match') }
|
12
|
+
it { expect(Experian::DataDictionary.lookup('0000', 'N')).to eq('Non-match') }
|
13
|
+
it { expect(Experian::DataDictionary.lookup('0000', '')).to eq('Non-match') }
|
14
|
+
it { expect(Experian::DataDictionary.lookup('0000', ' ')).to eq('Non-match') }
|
16
15
|
end
|
17
16
|
|
18
|
-
|
19
17
|
context 'invalid lookup' do
|
20
|
-
it { expect(
|
21
|
-
it { expect(
|
22
|
-
it { expect(
|
18
|
+
it { expect(Experian::DataDictionary.lookup('0000', 'D')).to be_nil }
|
19
|
+
it { expect(Experian::DataDictionary.lookup('0000', 'GG')).to be_nil }
|
20
|
+
it { expect(Experian::DataDictionary.lookup('0000', 'DOG')).to be_nil }
|
23
21
|
end
|
24
|
-
|
25
22
|
end
|
@@ -1,37 +1,30 @@
|
|
1
1
|
require File.join(Dir.pwd, 'spec', 'spec_helper')
|
2
2
|
|
3
3
|
describe 'Experian::DataDictionary 0100' do
|
4
|
-
|
5
4
|
context 'valid lookup' do
|
6
|
-
it { expect(
|
7
|
-
it { expect(
|
8
|
-
it { expect(
|
9
|
-
it { expect(
|
5
|
+
it { expect(Experian::DataDictionary.column_name('0100')).to eq('Date of Birth') }
|
6
|
+
it { expect(Experian::DataDictionary.lookup('0100', '198412')).to eq('12/1984') }
|
7
|
+
it { expect(Experian::DataDictionary.lookup('0100', '19931')).to eq('1/1993') }
|
8
|
+
it { expect(Experian::DataDictionary.lookup('0100', '19684')).to eq('4/1968') }
|
10
9
|
end
|
11
10
|
|
12
|
-
|
13
11
|
context 'invalid lookup' do
|
14
|
-
it { expect(
|
12
|
+
it { expect(Experian::DataDictionary.lookup('0100', '0')).to eq('0') }
|
15
13
|
end
|
16
|
-
|
17
14
|
end
|
18
15
|
|
19
16
|
describe 'Experian::DataDictionary 0100c' do
|
20
|
-
|
21
17
|
context 'valid lookup' do
|
22
|
-
it { expect(
|
23
|
-
it { expect(
|
24
|
-
it { expect(
|
25
|
-
it { expect(
|
26
|
-
it { expect(
|
27
|
-
|
18
|
+
it { expect(Experian::DataDictionary.column_name('0100c')).to eq('Combined Adult Age') }
|
19
|
+
it { expect(Experian::DataDictionary.lookup('0100c', 'e99')).to eq('99 - Exact age') }
|
20
|
+
it { expect(Experian::DataDictionary.lookup('0100c', 'i50')).to eq('50 - Estimated age') }
|
21
|
+
it { expect(Experian::DataDictionary.lookup('0100c', 'u')).to eq(' - Unknown age') }
|
22
|
+
it { expect(Experian::DataDictionary.lookup('0100c', '')).to eq('Unknown age') }
|
28
23
|
end
|
29
24
|
|
30
|
-
|
31
25
|
context 'invalid lookup' do
|
32
|
-
it { expect(
|
33
|
-
it { expect(
|
34
|
-
it { expect(
|
26
|
+
it { expect(Experian::DataDictionary.lookup('0100c', 'D')).to be_nil }
|
27
|
+
it { expect(Experian::DataDictionary.lookup('0100c', 'GG')).to be_nil }
|
28
|
+
it { expect(Experian::DataDictionary.lookup('0100c', 'DOG')).to be_nil }
|
35
29
|
end
|
36
|
-
|
37
30
|
end
|
@@ -1,21 +1,18 @@
|
|
1
1
|
require File.join(Dir.pwd, 'spec', 'spec_helper')
|
2
2
|
|
3
3
|
describe 'Experian::DataDictionary 0103' do
|
4
|
-
|
5
4
|
context 'valid lookup' do
|
6
|
-
it { expect(
|
7
|
-
it { expect(
|
8
|
-
it { expect(
|
9
|
-
it { expect(
|
10
|
-
it { expect(
|
5
|
+
it { expect(Experian::DataDictionary.column_name('0103')).to eq('Gender Code') }
|
6
|
+
it { expect(Experian::DataDictionary.lookup('0103', 'M')).to eq('Male') }
|
7
|
+
it { expect(Experian::DataDictionary.lookup('0103', 'F')).to eq('Female') }
|
8
|
+
it { expect(Experian::DataDictionary.lookup('0103', 'B')).to eq('Both') }
|
9
|
+
it { expect(Experian::DataDictionary.lookup('0103', 'U')).to eq('Unknown') }
|
11
10
|
end
|
12
11
|
|
13
|
-
|
14
12
|
context 'invalid lookup' do
|
15
|
-
it { expect(
|
16
|
-
it { expect(
|
17
|
-
it { expect(
|
18
|
-
it { expect(
|
13
|
+
it { expect(Experian::DataDictionary.lookup('0103', 'FF')).to be_nil }
|
14
|
+
it { expect(Experian::DataDictionary.lookup('0103', '0')).to be_nil }
|
15
|
+
it { expect(Experian::DataDictionary.lookup('0103', 'A')).to be_nil }
|
16
|
+
it { expect(Experian::DataDictionary.lookup('0103', 'R')).to be_nil }
|
19
17
|
end
|
20
|
-
|
21
18
|
end
|
@@ -1,21 +1,18 @@
|
|
1
1
|
require File.join(Dir.pwd, 'spec', 'spec_helper')
|
2
2
|
|
3
3
|
describe 'Experian::DataDictionary 0107A' do
|
4
|
-
|
5
4
|
context 'valid lookup' do
|
6
|
-
it { expect(
|
7
|
-
it { expect(
|
8
|
-
it { expect(
|
9
|
-
it { expect(
|
10
|
-
it { expect(
|
11
|
-
it { expect(
|
5
|
+
it { expect(Experian::DataDictionary.lookup('0107A', '1M')).to eq('Married - Extremely Likely') }
|
6
|
+
it { expect(Experian::DataDictionary.lookup('0107A', '1S')).to eq('Single - Extremely Likely') }
|
7
|
+
it { expect(Experian::DataDictionary.lookup('0107A', '5S')).to eq('Single - Likely') }
|
8
|
+
it { expect(Experian::DataDictionary.lookup('0107A', '5M')).to eq('Married - Likely') }
|
9
|
+
it { expect(Experian::DataDictionary.lookup('0107A', '0U')).to eq('Unknown Status - Unknown') }
|
10
|
+
it { expect(Experian::DataDictionary.lookup('0107A', '0')).to eq('Unknown') }
|
12
11
|
end
|
13
12
|
|
14
|
-
|
15
13
|
context 'invalid lookup' do
|
16
|
-
it { expect(
|
17
|
-
it { expect(
|
18
|
-
it { expect(
|
14
|
+
it { expect(Experian::DataDictionary.lookup('0107A', 'D')).to eq('Unknown') }
|
15
|
+
it { expect(Experian::DataDictionary.lookup('0107A', 'GG')).to eq('Unknown') }
|
16
|
+
it { expect(Experian::DataDictionary.lookup('0107A', 'DOG')).to eq('Unknown') }
|
19
17
|
end
|
20
|
-
|
21
|
-
end
|
18
|
+
end
|