ee.Reducer.ridgeRegression
קל לארגן דפים בעזרת אוספים
אפשר לשמור ולסווג תוכן על סמך ההעדפות שלך.
Creates a reducer that computes a ridge regression with numX independent variables (not including constant) followed by numY dependent variables. רגרסיית רכס היא סוג של רגולריזציה של טיכונוב שמקטינה את מקדמי הרגרסיה על ידי הטלת עונש על הגודל שלהם. בהטמעה הזו של רגרסיית Ridge, אין צורך לכלול ערך קבוע להטיה.
הפלט הראשון הוא מערך של מקדמים עם המימדים (numX + 1, numY). כל עמודה מכילה את המקדמים של המשתנה התלוי המתאים, בתוספת נקודת החיתוך של המשתנה התלוי בעמודה האחרונה. תוצאות נוספות הן וקטור של השורש הממוצע של ריבועי השאריות של כל משתנה תלוי, ווקטור של ערכי p לכל משתנה תלוי. הפלט הוא null אם המערכת לא מוגדרת, למשל אם מספר הקלטים קטן מ-numX + 1.
שימוש | החזרות |
---|
ee.Reducer.ridgeRegression(numX, numY, lambda) | הפחתה |
ארגומנט | סוג | פרטים |
---|
numX | מספר שלם | מספר המשתנים הבלתי תלויים שמתבצעת לגביהם רגרסיה. |
numY | מספר שלם, ברירת מחדל: 1 | מספר המשתנים התלויים. |
lambda | מספר ממשי (float), ברירת מחדל: 0.1 | פרמטר רגולריזציה. |
אלא אם צוין אחרת, התוכן של דף זה הוא ברישיון Creative Commons Attribution 4.0 ודוגמאות הקוד הן ברישיון Apache 2.0. לפרטים, ניתן לעיין במדיניות האתר Google Developers. Java הוא סימן מסחרי רשום של חברת Oracle ו/או של השותפים העצמאיים שלה.
עדכון אחרון: 2025-07-26 (שעון UTC).
[null,null,["עדכון אחרון: 2025-07-26 (שעון UTC)."],[[["\u003cp\u003eCreates a reducer for ridge regression, a regularization method that shrinks regression coefficients to prevent overfitting.\u003c/p\u003e\n"],["\u003cp\u003eOutputs include regression coefficients, root mean square of residuals, and p-values for each dependent variable.\u003c/p\u003e\n"],["\u003cp\u003eRequires specifying the number of independent and dependent variables, along with an optional regularization parameter (lambda).\u003c/p\u003e\n"],["\u003cp\u003eThe reducer automatically handles the intercept term, so there's no need to add a constant value for bias.\u003c/p\u003e\n"],["\u003cp\u003eOutputs will be null if the system is underdetermined, meaning there are fewer input data points than independent variables plus one.\u003c/p\u003e\n"]]],[],null,["# ee.Reducer.ridgeRegression\n\nCreates a reducer that computes a ridge regression with numX independent variables (not including constant) followed by numY dependent variables. Ridge regression is a form of Tikhonov regularization which shrinks the regression coefficients by imposing a penalty on their size. With this implementation of ridge regression there NO NEED to include a constant value for bias.\n\n\u003cbr /\u003e\n\nThe first output is a coefficients array with dimensions (numX + 1, numY); each column contains the coefficients for the corresponding dependent variable plus the intercept for the dependent variable in the last column. Additional outputs are a vector of the root mean square of the residuals of each dependent variable and a vector of p-values for each dependent variable. Outputs are null if the system is underdetermined, e.g., the number of inputs is less than numX + 1.\n\n| Usage | Returns |\n|-----------------------------------------------------------|---------|\n| `ee.Reducer.ridgeRegression(numX, `*numY* `, `*lambda*`)` | Reducer |\n\n| Argument | Type | Details |\n|----------|---------------------|------------------------------------------------------|\n| `numX` | Integer | the number of independent variables being regressed. |\n| `numY` | Integer, default: 1 | the number of dependent variables. |\n| `lambda` | Float, default: 0.1 | Regularization parameter. |"]]