Hej,
jag använder er historiska databas och försöker förstå vilken eller vilka variabler som motsvarar ssyk96 och ssyk2012.
Jag har två frågor gällande detta.
Fråga 1 är något invecklad:
Jag jobbar med datan i R, men har omvandlat historiska datans .jsonl-filer med följande Pythonscript (som eventuellt är från er?):
from os import listdir
from os.path import join, isfile
path = r"C:\Users\xmaaxe\Dropbox\Application Sweden\2. Job-ads\1. Exploration of the data (2023)\Monthly data"
for filename in listdir(path): # iterates over all the files in 'path'
if filename.endswith(".jsonl"):# open only if it is a jsonl file
print(filename)
with open(filename, 'r', encoding='utf-8', errors='ignore') as f: # open the file
data = [json.loads(line) for line in f.readlines()]
df = pd.json_normalize(data) # remove the levels of the json data and make them into columns
for col in df.columns: # correct the type for the columns, making them strings
df[col] = df[col].astype(str)
df.to_stata('%s.dta'%filename[0:7], version=118) # export this as a stata-file with the name without the extension
Efter att jag har importerat datan i R får jag följande variabler:
> colnames(X2006_01)
[1] "access" "access_to_own_car"
[3] "application_deadline" "driving_license"
[5] "driving_license_required" "experience_required"
[7] "external_id" "headline"
[9] "id" "last_publication_date"
[11] "logo_url" "number_of_vacancies"
[13] "publication_date" "removed"
[15] "removed_date" "salary_description"
[17] "source_type" "timestamp"
[19] "webpage_url" "application_details_email"
[21] "application_details_information" "application_details_other"
[23] "application_details_reference" "application_details_url"
[25] "application_details_via_af" "description_company_information"
[27] "description_conditions" "description_needs"
[29] "description_requirements" "description_text"
[31] "description_text_formatted" "duration_concept_id"
[33] "duration_label" "duration_legacy_ams_taxonomy_id"
[35] "employer_email" "employer_name"
[37] "employer_organization_number" "employer_phone_number"
[39] "employer_url" "employer_workplace"
[41] "employment_type_concept_id" "employment_type_label"
[43] "employment_type_legacy_ams_taxonomy_id" "must_have_languages"
[45] "must_have_skills" "must_have_work_experiences"
[47] "nice_to_have_languages" "nice_to_have_skills"
[49] "nice_to_have_work_experiences" "occupation_concept_id"
[51] "occupation_label" "occupation_legacy_ams_taxonomy_id"
[53] "occupation_field_concept_id" "occupation_field_label"
[55] "occupation_field_legacy_ams_taxonomy_id" "occupation_group_concept_id"
[57] "occupation_group_label" "occupation_group_legacy_ams_taxonomy_id"
[59] "salary_type_concept_id" "salary_type_label"
[61] "salary_type_legacy_ams_taxonomy_id" "scope_of_work_max"
[63] "scope_of_work_min" "working_hours_type_concept_id"
[65] "working_hours_type_label" "working_hours_type_legacy_ams_taxonomy_id"
[67] "workplace_address_city" "workplace_address_coordinates"
[69] "workplace_address_country" "workplace_address_country_code"
[71] "workplace_address_country_concept_id" "workplace_address_municipality"
[73] "workplace_address_municipality_code" "workplace_address_municipality_concept_id"
[75] "workplace_address_postcode" "workplace_address_region"
[77] "workplace_address_region_code" "workplace_address_region_concept_id"
[79] "workplace_address_street_address" "other_old_legacy_attributes_arbetsdrift"
[81] "other_old_legacy_attributes_dxa" "other_old_legacy_attributes_bil_krav"
[83] "other_old_legacy_attributes_tilltrade"
Ok.
Fråga 1:
Hur urskiljer jag vilken variabel som är ssyk-96 och ssyk2012?
occupation_group_legacy_ams_taxonomy_id
verkar vara ssyk12, stämmer det?
Det finns även andra, men jag förstår inte riktigt vad de är. Tex så verkar occupation_legacy_ams_taxonomy_id
inte matcha med varken 96 eller 12.
Fråga 2:
Det verkar som att det finns npn sorts ssyk-variabel i er API (se: Matcha LegacyAmsTaxonomyId med SSYK-2012?). Varför finns inte den i min databas? (kanske är det så att jag måste ladda ner den berikade versionen slår det mig nu…).
Mycket tacksam för hjälp.