BaşlayınÜcretsiz Başlayın

Transforming the response variable too

The response variable can be transformed too, but this means you need an extra step at the end to undo that transformation. That is, you "back transform" the predictions.

In the video, you saw the first step of the digital advertising workflow: spending money to buy ads, and counting how many people see them (the "impressions"). The next step is determining how many people click on the advert after seeing it.

ad_conversion is available as a pandas DataFrame.

Bu egzersiz

Introduction to Regression with statsmodels in Python

kursunun bir parçasıdır
Kursu Görüntüle

Uygulamalı interaktif egzersiz

Bu örnek kodu tamamlayarak bu egzersizi bitirin.

# Create qdrt_n_impressions and qdrt_n_clicks
ad_conversion["qdrt_n_impressions"] = ____
ad_conversion["qdrt_n_clicks"] = ____

plt.figure()

# Plot using the transformed variables
sns.regplot(____)
plt.show()
Kodu Düzenle ve Çalıştır