applift datathon- predict bdiing
TRANSCRIPT
![Page 1: Applift datathon- predict bdiing](https://reader035.vdocuments.mx/reader035/viewer/2022062821/589c47ce1a28ab227d8b5229/html5/thumbnails/1.jpg)
Predict...
![Page 2: Applift datathon- predict bdiing](https://reader035.vdocuments.mx/reader035/viewer/2022062821/589c47ce1a28ab227d8b5229/html5/thumbnails/2.jpg)
• kept:• TrafficType str: site/app• PublisherId str: brand value of publisher• AppSiteId str : brand value of app/site• AppSiteCategory str: arts,travel: genre• Position str: top/bottom• OS str• OSVersion str• DeviceType str• DeviceIP str (perhaps!!)• Country str• CampaignId int• CreativeId int• CreativeType int• CreativeCategory str• ExchangeBid float
![Page 3: Applift datathon- predict bdiing](https://reader035.vdocuments.mx/reader035/viewer/2022062821/589c47ce1a28ab227d8b5229/html5/thumbnails/3.jpg)
removed
• BidId str unique• BidFloor int same• Timestamp int ignored• Age int not enuf data• Gender str --do--• Carrier str• DeviceIdstr all 0• Latitude str• Longitude str• Zipcode int• GeoTypestr
![Page 4: Applift datathon- predict bdiing](https://reader035.vdocuments.mx/reader035/viewer/2022062821/589c47ce1a28ab227d8b5229/html5/thumbnails/4.jpg)
![Page 5: Applift datathon- predict bdiing](https://reader035.vdocuments.mx/reader035/viewer/2022062821/589c47ce1a28ab227d8b5229/html5/thumbnails/5.jpg)
![Page 6: Applift datathon- predict bdiing](https://reader035.vdocuments.mx/reader035/viewer/2022062821/589c47ce1a28ab227d8b5229/html5/thumbnails/6.jpg)
Filtering…
• Finding sentiment
![Page 7: Applift datathon- predict bdiing](https://reader035.vdocuments.mx/reader035/viewer/2022062821/589c47ce1a28ab227d8b5229/html5/thumbnails/7.jpg)
•• A popular approach towards solving class imbalance problems is to bias
the classifier so that it pays more attention to the positive instances.• This can be done, for instance, by increasing the penalty associated with
misclassifying the positive class relative to the negative class. • Another approach is to preprocess the data by oversampling the majority
class or undersampling the minority class in order to create a balanced dataset.
![Page 8: Applift datathon- predict bdiing](https://reader035.vdocuments.mx/reader035/viewer/2022062821/589c47ce1a28ab227d8b5229/html5/thumbnails/8.jpg)
![Page 9: Applift datathon- predict bdiing](https://reader035.vdocuments.mx/reader035/viewer/2022062821/589c47ce1a28ab227d8b5229/html5/thumbnails/9.jpg)
learn• model=graphlab.logistic_classifier.create(train_data,target='sentiment',fea
tures=['TrafficType','DeviceType','CampaignId','CreativeCategory','ExchangeBid'],validation_set=test_data,max_iterations=500)
![Page 10: Applift datathon- predict bdiing](https://reader035.vdocuments.mx/reader035/viewer/2022062821/589c47ce1a28ab227d8b5229/html5/thumbnails/10.jpg)
![Page 11: Applift datathon- predict bdiing](https://reader035.vdocuments.mx/reader035/viewer/2022062821/589c47ce1a28ab227d8b5229/html5/thumbnails/11.jpg)
Evaluate..
• model.evaluate(test_data)
![Page 12: Applift datathon- predict bdiing](https://reader035.vdocuments.mx/reader035/viewer/2022062821/589c47ce1a28ab227d8b5229/html5/thumbnails/12.jpg)
![Page 13: Applift datathon- predict bdiing](https://reader035.vdocuments.mx/reader035/viewer/2022062821/589c47ce1a28ab227d8b5229/html5/thumbnails/13.jpg)
![Page 14: Applift datathon- predict bdiing](https://reader035.vdocuments.mx/reader035/viewer/2022062821/589c47ce1a28ab227d8b5229/html5/thumbnails/14.jpg)
![Page 15: Applift datathon- predict bdiing](https://reader035.vdocuments.mx/reader035/viewer/2022062821/589c47ce1a28ab227d8b5229/html5/thumbnails/15.jpg)
![Page 16: Applift datathon- predict bdiing](https://reader035.vdocuments.mx/reader035/viewer/2022062821/589c47ce1a28ab227d8b5229/html5/thumbnails/16.jpg)
evaluate
• import graphlab• model=graphlab.load_model('mymodel/')• eval=graphlab.SFrame('data/eval1.csv')• eval['sentiment']=eval['Outcome']!='0'• model.evaluate(eval)
OR• eval['predict']=model.predict(eval,output_type='probability')