LoslegenKostenlos loslegen

Fitting t-SNE to the ANSUR data

t-SNE is a great technique for visual exploration of high dimensional datasets. In this exercise, you'll apply it to the ANSUR dataset. You'll remove non-numeric columns from the pre-loaded dataset df and fit TSNE to this numeric dataset.

Diese Übung ist Teil des Kurses

Dimensionality Reduction in Python

Kurs anzeigen

Anleitung zur Übung

  • Drop the non-numeric columns from the dataset.
  • Create a TSNE model with learning rate 50.
  • Fit and transform the model on the numeric dataset.

Interaktive Übung

Vervollständige den Beispielcode, um diese Übung erfolgreich abzuschließen.

# Non-numerical columns in the dataset
non_numeric = ['Branch', 'Gender', 'Component']

# Drop the non-numerical columns from df
df_numeric = df.____(____, axis=____)

# Create a t-SNE model with learning rate 50
m = ____(____)

# Fit and transform the t-SNE model on the numeric dataset
tsne_features = m.____(____)
print(tsne_features.shape)
Code bearbeiten und ausführen