Coming straight from the Machine Learning course on Udemy, the lecture about Encoding categorical data has provided a CSV file to code-along.
The content of the file are fairly simple:

Creating the matrix of features, I can get the data fairly easily with the values as it is.
But on using OneHotEncoder from sklearn (comlumn transformer), the "country column" split into 3 different column gives values as shown below:

The lecturer however, gets single decimal places for the same data and same code. Can't seem to understand if I am doing something wrong, or if there is a change in version of the platform that is responsible for this. How can I get the single decimal places instead of multiple zeros.
The code for encoding:
from sklearn.compose import ColumnTransformer
from sklearn.preprocessing import OneHotEncoder
ct = ColumnTransformer(transformers =[('encoder',OneHotEncoder(),[0])], remainder = 'passthrough')
X = np.array(ct.fit_transform(X))
Edit:
Expected output for row 1:
[1.0 0.0 0.0 44.0 72000.0]
Output that I get:
[1.00000000e+00 0.00000000e+00 0.00000000e+00 4.40000000e+01 7.20000000e+04]
[1,0,0]or something else? Also, do you want to OneHot encode only the country column? - Green1.0and1.0000e+00are both exactly the same data type and value. - Swier