-- DBMS: bigquery
CREATE TABLE `bigquery-public-data.cms_medicare.home_health_agencies_2014`
(
  provider_id STRING OPTIONS(description="The 6-digit identification number for the home health agency on the claim."),
  agency_name STRING OPTIONS(description="The home health agency name, as reported in the POS file."),
  street_address STRING OPTIONS(description="The home health agency address, as reported in the POS file."),
  city STRING OPTIONS(description="The city where the home health agency is located, as reported in the POS file."),
  state STRING OPTIONS(description="The state where the home health agency is located, as reported in POS file. The fifty U.S. states and the District of Columbia are reported by the state postal abbreviation."),
  zip_code INT64 OPTIONS(description="The home health agency’s zip code, as reported in the POS file."),
  total_episodes_non_lupa INT64 OPTIONS(description="Total count of non-LUPA episodes provided by a specific home health agency or in a unique HHRG category in the calendar year."),
  distinct_beneficiaries_non_lupa INT64 OPTIONS(description="Number of distinct Medicare beneficiaries receiving at least one non-LUPA home health episode in the calendar year. Beneficiaries may receive multiple home health episodes per year but are only counted once in this field."),
  average_number_of_total_visits_per_episode_non_lupa FLOAT64 OPTIONS(description="Average number of total visits provided by the HHA during a non-LUPA episode."),
  average_number_of_skilled_nursing_visits_per_episode_non_lupa FLOAT64 OPTIONS(description="Average number of skilled nursing visits provided by the HHA during a non-LUPA episode."),
  average_number_of_pt_visits_per_episode_non_lupa FLOAT64 OPTIONS(description="Average number of physical therapy visits provided by the HHA during a non-LUPA episode."),
  average_number_of_ot_visits_per_episode_non_lupa FLOAT64 OPTIONS(description="Average number of occupational therapy visits provided by the HHA during a non-LUPA episode."),
  average_number_of_st_visits_per_episode_non_lupa FLOAT64 OPTIONS(description="Average number of speech therapy visits provided by the HHA during a non-LUPA episode."),
  average_number_of_home_health_aide_visits_per_episode_non_lupa FLOAT64 OPTIONS(description="Average number of home health aide visits provided by the HHA during a non-LUPA episode."),
  average_number_of_medical_social_visits_per_episode_non_lupa FLOAT64 OPTIONS(description="Average number of medical-social visits provided by the HHA during a non-LUPA episode."),
  total_hha_charge_amount_non_lupa INT64 OPTIONS(description="Total charges that the home health agency submitted for non-LUPA episodes."),
  total_hha_medicare_payment_amount_non_lupa INT64 OPTIONS(description="Total amount that Medicare paid for non-LUPA episodes. Home health services do not have any cost-sharing requirements and the Medicare payment amount will equal the allowed amount."),
  total_hha_medicare_standard_payment_amount_non_lupa INT64 OPTIONS(description="Total amount that Medicare paid for non-LUPA episodes adjusted for geographic differences in payment rates."),
  outlier_payments_as_a_percent_of_medicare_payment_amount_non_lupa FLOAT64 OPTIONS(description="The percent of total Medicare payments for non-LUPA episodes paid to an HHA for outlier episodes."),
  total_lupa_episodes INT64 OPTIONS(description="Total count of low utilization payment amount episodes provided by a specific HHA in the calendar year."),
  total_hha_medicare_payment_amount_for_lupas INT64 OPTIONS(description="Total amount that Medicare paid for LUPA episodes provided by a specific HHA in the calendar year."),
  average_age INT64 OPTIONS(description="Average age of beneficiaries. Beneficiary age is calculated at the end of the calendar year or at the time of death."),
  male_beneficiaries INT64 OPTIONS(description="Number of male beneficiaries."),
  female_beneficiaries INT64 OPTIONS(description="Number of female beneficiaries."),
  nondual_beneficiaries INT64 OPTIONS(description="Number of Medicare beneficiaries qualified to receive Medicare only benefits. Beneficiaries are classified as Medicare only entitlement if they received zero months of any Medicaid benefits (full or partial) in the given calendar year."),
  dua_beneficiaries INT64 OPTIONS(description="Number of Medicare beneficiaries qualified to receive Medicare and Medicaid benefits. Beneficiaries are classified as Medicare and Medicaid entitlement if in any month in the given calendar year they were receiving full or partial Medicaid benefits."),
  white_beneficiaries INT64 OPTIONS(description="Number of non-Hispanic white beneficiaries."),
  black_beneficiaries INT64 OPTIONS(description="Number of non-Hispanic black or African American beneficiaries."),
  asian_pacific_islander_beneficiaries INT64 OPTIONS(description="Number of Asian Pacific Islander beneficiaries."),
  hispanic_beneficiaries INT64 OPTIONS(description="Number of Hispanic beneficiaries."),
  american_indian_or_alaska_native_beneficiaries INT64 OPTIONS(description="Number of American Indian or Alaska Native beneficiaries."),
  other_unknown_beneficiaries INT64 OPTIONS(description="Number of beneficiaries with race not elsewhere classified."),
  average_hcc_score FLOAT64 OPTIONS(description="Average Hierarchical Condition Category (HCC) risk score of beneficiaries. Please refer to the “Additional Information” section of the Methodology document for more details on HCC risk scores."),
  percent_of_beneficiaries_with_atrial_fibrillation INT64 OPTIONS(description="Percent of beneficiaries meeting the CCW chronic condition algorithm for atrial fibrillation."),
  percent_of_beneficiaries_with_alzheimers INT64 OPTIONS(description="Percent of beneficiaries meeting the CCW chronic condition algorithm for Alzheimer’s, related disorders, or dementia."),
  percent_of_beneficiaries_with_asthma INT64 OPTIONS(description="Percent of beneficiaries meeting the CCW chronic condition algorithm for Asthma."),
  percent_of_beneficiaries_with_cancer INT64 OPTIONS(description="Percent of beneficiaries meeting the CCW chronic condition algorithms for cancer. Includes breast cancer, colorectal cancer, lung cancer and prostate cancer."),
  percent_of_beneficiaries_with_chf INT64 OPTIONS(description="Percent of beneficiaries meeting the CCW chronic condition algorithm for heart failure."),
  percent_of_beneficiaries_with_chronic_kidney_disease INT64 OPTIONS(description="Percent of beneficiaries meeting the CCW chronic condition algorithm for chronic kidney disease."),
  percent_of_beneficiaries_with_copd INT64 OPTIONS(description="Percent of beneficiaries meeting the CCW chronic condition algorithm for chronic obstructive pulmonary disease."),
  percent_of_beneficiaries_with_depression INT64 OPTIONS(description="Percent of beneficiaries meeting the CCW chronic condition algorithm for depression."),
  percent_of_beneficiaries_with_diabetes INT64 OPTIONS(description="Percent of beneficiaries meeting the CCW chronic condition algorithm for diabetes."),
  percent_of_beneficiaries_with_hyperlipidemia INT64 OPTIONS(description="Percent of beneficiaries meeting the CCW chronic condition algorithm for hyperlipidemia."),
  percent_of_beneficiaries_with_hypertension INT64 OPTIONS(description="Percent of beneficiaries meeting the CCW chronic condition algorithm for hypertension."),
  percent_of_beneficiaries_with_ihd INT64 OPTIONS(description="Percent of beneficiaries meeting the CCW chronic condition algorithm for ischemic heart disease."),
  percent_of_beneficiaries_with_osteoporosis INT64 OPTIONS(description="Percent of beneficiaries meeting the CCW chronic condition algorithm for osteoporosis."),
  percent_of_beneficiaries_with_ra_oa INT64 OPTIONS(description="Percent of beneficiaries meeting the CCW chronic condition algorithm for rheumatoid arthritis/osteoarthritis."),
  percent_of_beneficiaries_with_schizophrenia INT64 OPTIONS(description="Percent of beneficiaries meeting the CCW chronic condition algorithm for schizophrenia and other psychotic disorders."),
  percent_of_beneficiaries_with_stroke INT64 OPTIONS(description="Percent of beneficiaries meeting the CCW chronic condition algorithm for stroke.")
);

INSERT INTO `bigquery-public-data.cms_medicare.home_health_agencies_2014` (provider_id, agency_name, street_address, city, state, zip_code, total_episodes_non_lupa, distinct_beneficiaries_non_lupa, average_number_of_total_visits_per_episode_non_lupa, average_number_of_skilled_nursing_visits_per_episode_non_lupa, average_number_of_pt_visits_per_episode_non_lupa, average_number_of_ot_visits_per_episode_non_lupa, average_number_of_st_visits_per_episode_non_lupa, average_number_of_home_health_aide_visits_per_episode_non_lupa, average_number_of_medical_social_visits_per_episode_non_lupa, total_hha_charge_amount_non_lupa, total_hha_medicare_payment_amount_non_lupa, total_hha_medicare_standard_payment_amount_non_lupa, outlier_payments_as_a_percent_of_medicare_payment_amount_non_lupa, total_lupa_episodes, total_hha_medicare_payment_amount_for_lupas, average_age, male_beneficiaries, female_beneficiaries, nondual_beneficiaries, dua_beneficiaries, white_beneficiaries, black_beneficiaries, asian_pacific_islander_beneficiaries, hispanic_beneficiaries, american_indian_or_alaska_native_beneficiaries, other_unknown_beneficiaries, average_hcc_score, percent_of_beneficiaries_with_atrial_fibrillation, percent_of_beneficiaries_with_alzheimers, percent_of_beneficiaries_with_asthma, percent_of_beneficiaries_with_cancer, percent_of_beneficiaries_with_chf, percent_of_beneficiaries_with_chronic_kidney_disease, percent_of_beneficiaries_with_copd, percent_of_beneficiaries_with_depression, percent_of_beneficiaries_with_diabetes, percent_of_beneficiaries_with_hyperlipidemia, percent_of_beneficiaries_with_hypertension, percent_of_beneficiaries_with_ihd, percent_of_beneficiaries_with_osteoporosis, percent_of_beneficiaries_with_ra_oa, percent_of_beneficiaries_with_schizophrenia, percent_of_beneficiaries_with_stroke) VALUES ('58330', 'DIVINE HOME HEALTH, INC', '14625 CARMENITA ROAD SUITE 228', 'NORWALK', 'CA', 90650, 681, 486, 13.4, 9.8, 2.7, 0.1, 0.0, 0.8, 0.0, 1368276, 2217148, 1787361, 6.5, 31, 12912, 80, 139, 347, 55, 431, 35, NULL, 407, 26, NULL, 17, 2.0, 9, 39, 15, 8, 30, 39, 16, 21, 74, 70, NULL, 57, 44, 72, 4, 8), ('58376', 'ORANGE COUNTY CARE PROVIDERS, INC', '14700 E FIRESTONE BLVD SUITE 128', 'LA MIRADA', 'CA', 90638, 614, 293, 18.0, 12.8, 4.3, 0.1, 0.1, 0.7, 0.0, 1652285, 2137998, 1747600, 6.2, 44, 16321, 82, 97, 196, 92, 201, 189, NULL, 63, NULL, NULL, 28, 2.74, 24, 46, 19, 16, 45, 51, 37, 49, 49, 72, NULL, 54, 19, 67, 7, 12), ('147844', 'ALERT HOME HEALTH CARE, INC', '8118 N MILWAUKEE AVENUE, STE 109', 'NILES', 'IL', 60714, 501, 197, 10.4, 7.5, 1.5, 0.1, 0.0, 1.3, 0.0, 669226, 1189842, 1165889, 0.0, 43, 11642, 79, 58, 139, 81, 116, 149, NULL, 17, NULL, NULL, 13, 2.16, 23, 27, 20, 9, 52, 32, 28, 39, 68, 73, NULL, 68, 23, NULL, 3, 10), ('227290', 'SUBURBAN HOME HEALTH CARE, INC', '1050 COMMONWEALTH AVE', 'BOSTON', 'MA', 2115, 1466, 696, 31.9, 17.2, 4.6, 0.5, 0.2, 9.5, 0.0, 5856605, 5549658, 4418284, 8.8, 58, 23848, 82, 203, 493, 117, 579, 476, 31, 108, NULL, NULL, 71, 2.25, 28, 33, 14, 14, 48, 49, 16, 40, 54, 64, NULL, 63, 16, 62, 10, 7), ('747139', 'KOREAN HOME HEALTH', '1908 ROYAL LANE SUITE 100', 'DALLAS', 'TX', 75229, 1691, 419, 15.0, 8.3, 1.8, 0.1, 0.0, 4.7, 0.0, 3811831, 3725304, 3914596, 0.0, 24, 8595, 78, 146, 273, 75, 344, NULL, NULL, 384, NULL, NULL, 17, 1.5, 6, 31, 12, 4, 28, 31, 16, 16, 53, NULL, NULL, 33, 35, 74, 2, 6);