Seção 1. Capítulo 4
single
Challenge: Building a Feature Pipeline for Customer Data
Deslize para mostrar o menu
Tarefa
Deslize para começar a programar
You are given a flights dataset as a list of rows. Load it into a DataFrame using createDataFrame and apply the encoding and scaling techniques from the previous chapters. Store results in the specified variables:
- Fill nulls in
DelayandLengthwith0; - Apply
StringIndexertoAirline– store the result in a columnAIRLINE_IDX; - Apply
OneHotEncodertoAIRLINE_IDX– store the result in a columnAIRLINE_VEC; - Assemble
Length,Time, andAIRLINE_IDXinto a vector columnFEATURES_RAW; - Apply
StandardScalerwithwithMean=TrueandwithStd=TruetoFEATURES_RAW– store the result inFEATURES_SCALED; - Store the final DataFrame in
features_dfand count its rows infeatures_count.
Print features_count and show all rows of Airline, AIRLINE_VEC, FEATURES_SCALED.
Solução
Tudo estava claro?
Obrigado pelo seu feedback!
Seção 1. Capítulo 4
single
Pergunte à IA
Pergunte à IA
Pergunte o que quiser ou experimente uma das perguntas sugeridas para iniciar nosso bate-papo