1 / 24

כריית מידע – רגרסיה Regression

כריית מידע – רגרסיה Regression. ד"ר אבי רוזנפלד. שימושי רגרסיה. ניבוי יש אוסף של נתונים ואנחנו רוצים להבין מה יהיה בעתיד דוגמא: רגרסיה לינארית (עשייתם כבר) סיווג יש אוסף של נתונים ואנחנו רוצים לקטלג אותם גם אפשר רגרסיה לינארית SVM ( Support Vector Machine ) Logistic Regression

caine
Download Presentation

כריית מידע – רגרסיה Regression

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. כריית מידע – רגרסיהRegression ד"ר אבי רוזנפלד

  2. שימושי רגרסיה • ניבוי • יש אוסף של נתונים ואנחנו רוצים להבין מה יהיה בעתיד • דוגמא:רגרסיה לינארית (עשייתם כבר) • סיווג • יש אוסף של נתונים ואנחנו רוצים לקטלג אותם • גם אפשר רגרסיה לינארית • SVM (Support Vector Machine) • Logistic Regression • נושא של ההרצאה היום 

  3. רגרסיה לינארית למען ניבוי Regression Dependent variable Independent variable (x) יש לך אוסף של נתונים מכניסים קו שהוא מצמצם איזשהו מדד של טעות אם הצלחנו, זה כלי טוב לניבוי

  4. דוגמא

  5. מה מנסים לצמצם?Which Objective Function? • טעות מוחלט (Least Absolute Error) • טעות בריבוע (Least Square Error)

  6. רגרסיה לא לינארית Nonlinear Regression Nonlinear functions can also be fit as regressions. Common choices include Power, Logarithmic, Exponential, and Logistic, but any continuous function can be used.

  7. רגרסיה למען סיווג – עץ החלטות

  8. מודל פשוט יותר -- רגרסיה

  9. הבעיה– לא תמיד ברור איפה לחתוך

  10. הבדלים בדיוק בין מודלים

  11. SVMהרעיון הכללי– למקסם רווח בין הקטגוריות

  12. הגדרת הפתרון • קיים: אוסף של נתונים ש X הוא הוקטורשל מאפיינים וY הם הקטגוריות במצב אידיאלי אנחנו רוצים:

  13. לפי ההגדות...

  14. אבל המציאות לא תמיד נותן... • יש צורך להקטין את הHINGE LOSS, או המופעים שהם בצד ה"לא נכון" • HINGE LOSS הוא רק פונקציה אחת של LOSS

  15. הנוסחאות...

  16. Linear SVM Mathematically • Goal: 1) Correctly classify all training data if yi = +1 if yi = -1 for all i 2) Maximize the Margin same as minimize • We can formulate a Quadratic Optimization Problem and solve for w and b • Minimize subject to

  17. Solving the Optimization Problem Find w and b such that Φ(w) =½ wTw is minimized; and for all {(xi,yi)}: yi (wTxi+ b)≥ 1 • Need to optimize a quadratic function subject to linear constraints. • Quadratic optimization problems are a well-known class of mathematical programming problems, and many (rather intricate) algorithms exist for solving them. • The solution involves constructing a dual problem where a Lagrange multiplierαi is associated with every constraint in the primary problem: Find α1…αNsuch that Q(α) =Σαi- ½ΣΣαiαjyiyjxiTxjis maximized and (1)Σαiyi= 0 (2) αi≥ 0 for all αi

  18. שיפורים נוספים • שימוש בפונקציה לא לינארית (Kernel Trick) • פולינומים • GAUSIAN • ועוד...

  19. רגרסיה הסתברותיתLogistic Regression • שימוש בOBJECTIVE FUNCTION הסתברותי (logistic) • מקטלג קרוב ל1 ו1- אומר הסתברות גבוה is the intercept where f(x)=0 controls the graph shape

  20. איך הופכים קטגוריות להסתברות • שימו לב שLOGISTIC REGRESSION מוציא בתור פלט קטגוריות (ולא מספרים) • הוא מתרגם את המספרים לlog-odds

  21. הבדלים עקרוניים בין המודלים • עצים בנויים אינקרמנטליים– שלב שלב • רגרסיה בונה משקל לכל פרמטר בו זמנית • רגרסיה מחלקת רק לפי צורת הפונקציה (לינארית, LOGISTIC, וכו'). עצים יותר גמישים. • יש יותר משמעות לפלט של העץ (הרופאים ורוב לקוחות מעדיפים אותם) • יכול להיות שיש דיוק יותר טוב לרגרסיה

  22. הפלט של רגרסיה

  23. הפלט של עצים

  24. שינויים בין המודלים ברגרסיה – לא תמיד חלוקה לינארית

More Related