Page 1 of 1

PLEASE DO NOT SEND ME OTHER QUESTION'S ANSWER (b) Except for the months of service and number of incidents, all the othe

Posted: Sun Sep 05, 2021 5:01 pm
by answerhappygod
PLEASE DO NOT SEND ME OTHER QUESTION'S ANSWER
(b) Except for the months of service and number of incidents,
all the other variables, including "types", "c_years", and
"o_periods" are actually nominal and not interval/ratio.
(i) Perform an appropriate data type conversion for these
variables so that they can be recognised as categorical
variables.
(ii) Construct Python code to convert all categorical variables
to dummy variables and save the result as a pandas DataFrame named
"X".
(iii) Researchers suggest that the aggregated months of service
of each ship must be scaled down due to its wide range of values.
Perform a log-transformation of this variable in the DataFrame and
name the transformed variable "log_s_months". The transformed
variable should be attached to both DataFrames "X" and "ship".
Additional info:
ship types to "types", construction years to "c_years",
operation periods to "o_periods", the aggregated months of service
to "s_months", and the number of incidents to "incidents".