{"id":102,"date":"2025-02-12T06:27:08","date_gmt":"2025-02-12T06:27:08","guid":{"rendered":"https:\/\/riespw.com\/blog\/?p=102"},"modified":"2025-02-12T06:27:09","modified_gmt":"2025-02-12T06:27:09","slug":"ml-linear-regression","status":"publish","type":"post","link":"https:\/\/riespw.com\/blog\/2025\/02\/12\/ml-linear-regression\/","title":{"rendered":"ML: Linear Regression"},"content":{"rendered":"\n<p class=\"has-text-color has-link-color wp-elements-3c76bd0cda5ca31bb8b47fcb0045028a\" style=\"color:#fffffffa\">In statistics, linear regression is a model that estimates the linear relationship between a scalar response (dependent variable) and one or more explanatory variables (regressor or independent variable). A model with exactly one explanatory variable is a simple linear regression; a model with two or more explanatory variables is a multiple linear regression.[1] This term is distinct from multivariate linear regression, which predicts multiple correlated dependent variables rather than a single dependent variable.[2]<\/p>\n\n\n\n<p><em>Dalam statistik, linear regression adalah model yang meng-estimasi hubungan linear antara respon skalar (variabel dependent) dan satu atau lebih variabel penjelas (regressor atau variabel independen). Model dengan tepat satu variabel penjelas adalah linear regression versi simpel; model dengan dua atau lebih variabel penjelas adalah linear regression multiple.[1] Term ini berbeda dari linear regression multivariate, yang memprediksi berbagai variabel dependensi yang terkorelasi bukannya variabel dependensi single.<\/em><\/p>\n\n\n\n<p class=\"has-text-color has-link-color wp-elements-7709bac72d7010fc8fa7a94d116e9d13\" style=\"color:#ffffff\">In linear regression, the relationships are modeled using linear predictor functions whose unknown model parameters are estimated from the data. Most commonly, the conditional mean of the response given the values of the explanatory variables (or predictors) is assumed to be an affine function of those values; less commonly, the conditional median or some other quantile is used. Like all forms of regression analysis, linear regression focuses on the conditional probability distribution of the response given the values of the predictors, rather than on the joint probability distribution of all of these variables, which is the domain of multivariate analysis.<\/p>\n\n\n\n<p><em>Dalam linear regression, model hubungan dibuat berdasarkan fungsi prediktor linear dengan parameter yang tidak diketahui yang di estimasi dari data. Umumnya,  rata-rata kondisional dari respons yang diberikan nilai-nilai variabel penjelas (atau prediktor) diasumsikan sebagai fungsi afine dari nilai-nilai tersebut; lebih jarang, median kondisional atau beberapa kuantil lainnya digunakan.<\/em> <em>Seperti bentuk lainnya dari regression analysis, linear regression fokus pada distribusi probabilitas <em>respon <\/em><\/em><em>yang didistribusikan berdasarkan nilai dari prediktor, dan bukan berdasarkan distribusi probabilitas gabungan dari semua variabel ini, yang adalah domain dari multivariate analysis.  <\/em><\/p>\n\n\n\n<p class=\"has-text-color has-link-color wp-elements-bf5e9a3a40117dfc5776ce8e4d74b5f3\" style=\"color:#ffffff\">Linear regression is also a type of machine learning algorithm, more specifically a supervised algorithm, that learns from the labelled datasets and maps the data points to the most optimized linear functions that can be used for prediction on new datasets. [3]<\/p>\n\n\n\n<p><em>Regresi linear juga adalah tipe algoritma machine learning, lebih tepatnya algoritma supervised, yang dapat belajar dari dataset yang sudah diberi label dan memetakan data points kepada fungsi linear yang paling optimal yang dapat digunakan untuk memprediksi dataset yang baru.<\/em><\/p>\n\n\n\n<p class=\"has-text-color has-link-color wp-elements-243d1c8158bed0056c110d7596046452\" style=\"color:#ffffff\">Linear regression was the first type of regression analysis to be studied rigorously, and to be used extensively in practical applications.[4] This is because models which depend linearly on their unknown parameters are easier to fit than models which are non-linearly related to their parameters and because the statistical properties of the resulting estimators are easier to determine.<\/p>\n\n\n\n<p><em>Regresi linear adalah tipe pertama dari regression analysis yang dipelajari secara menyeluruh, dan digunakan secara luas pada aplikasi praktikal. Ini karena model yang bergantung secara linear kepada parameter unknowns lebih mudah untuk fit daripada model yang tidak linear kepada parameter mereka dan karena atribut statistik dari estimasi yang dihasilkan jauh lebih mudah untuk ditentukan.<\/em><\/p>\n\n\n\n<p class=\"has-text-color has-link-color wp-elements-a6ed0df7ab8930cee54d70933913e4ca\" style=\"color:#ffffff\">Linear regression has many practical uses. Most applications fall into one of the following two broad categories:<\/p>\n\n\n\n<p><em>Regresi linear memiliki banyak kegunaan praktis. Sebagian besar aplikasi jatuh kepada dua kategori besar berikut:<\/em><\/p>\n\n\n\n<p class=\"has-text-color has-link-color wp-elements-76025fa9840c74e0210f9a678bd9b5f7\" style=\"color:#ffffff\">If the goal is error i.e. variance reduction in prediction or forecasting, linear regression can be used to fit a predictive model to an observed data set of values of the response and explanatory variables. After developing such a model, if additional values of the explanatory variables are collected without an accompanying response value, the fitted model can be used to make a prediction of the response.<\/p>\n\n\n\n<p><em>Jika tujuan akhirnya adalah error (e.e. reduksi variasi pada prediksi atau ramalan), regresi linear dapat digunakan untuk memasangkan model prediktif kepada data set respons dan variabel penjelas yang telah diamati. Setelah mengembangkan model seperti itu, jika nilai tambahan dari variabel penjelas didapatkan tanpa nilai respon, model yang telah di fitted dapat digunakan untuk membuat prediksi respons.<\/em> <\/p>\n\n\n\n<p class=\"has-text-color has-link-color wp-elements-e61f50843a4afa7b3af3dedcab3afa74\" style=\"color:#ffffff\">If the goal is to explain variation in the response variable that can be attributed to variation in the explanatory variables, linear regression analysis can be applied to quantify the strength of the relationship between the response and the explanatory variables, and in particular to determine whether some explanatory variables may have no linear relationship with the response at all, or to identify which subsets of explanatory variables may contain redundant information about the response.<\/p>\n\n\n\n<p><em>Jika tujuannya adalah menjelaskan variasi dari variabel respon yang dapat diatribusikan kepada variasi dalam variabel penjelas, analisis regresi linear dapat diaplikasikan untuk mengukur kekuatan dari hubungan antara respon dan variabel penjelas, dan secara khusus untuk menentukan apakah variabel penjelas tertentu mungkin tidak memiliki hubungan linear dengan respon sama sekali, atau untuk mengidentifikasi subset dari variabel penjelas yang mana yang mungkin mengandung informasi redundan dari respons.<\/em><\/p>\n\n\n\n<p class=\"has-text-color has-link-color wp-elements-8945def9ce7dbff49db9f56410a229d9\" style=\"color:#ffffff\">Linear regression models are often fitted using the least squares approach, but they may also be fitted in other ways, such as by minimizing the &#8220;lack of fit&#8221; in some other norm (as with least absolute deviations regression), or by minimizing a penalized version of the least squares cost function as in ridge regression (L2-norm penalty) and lasso (L1-norm penalty). Use of the Mean Squared Error (MSE) as the cost on a dataset that has many large outliers, can result in a model that fits the outliers more than the true data due to the higher importance assigned by MSE to large errors. So, cost functions that are robust to outliers should be used if the dataset has many large outliers. Conversely, the least squares approach can be used to fit models that are not linear models. Thus, although the terms &#8220;least squares&#8221; and &#8220;linear model&#8221; are closely linked, they are not synonymous.<\/p>\n\n\n\n<p><em>Model regresi linear biasanya di fit menggunakan pendekatan least squares, tetapi kadang mereka juga di fit menggunakan cara lain, seperti meminimalisasi &#8220;lack of fit&#8221; pada norma lain (seperti dengan least absolute deviations regression), atau dengan meminimalisasi versi penalized dari fungsi biaya least squares seperti dalam ridge regression (L2-norm penalty) dan lasso (L1-norm penalty). Penggunaan Mean Squared Error (MSE) sebagai biaya pada dataset yang memiliki banyak outlier yang besar. Sebaliknya, pendekatan least square dapat digunakan untuk melakukan fit pada model yang bukan model linear. Maka, meskipun term &#8220;least squares&#8221; dan &#8220;linear model&#8221; terhubung secara dekat, mereka tidak sinonim.<\/em> <\/p>\n","protected":false},"excerpt":{"rendered":"<p>In statistics, linear regression is a model that estimates the linear relationship between a scalar response (dependent variable) and one or more explanatory variables (regressor or independent variable). A model with exactly one explanatory variable is a simple linear regression; a model with two or more explanatory variables is a multiple linear regression.[1] This term [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[1],"tags":[],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/riespw.com\/blog\/wp-json\/wp\/v2\/posts\/102"}],"collection":[{"href":"https:\/\/riespw.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/riespw.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/riespw.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/riespw.com\/blog\/wp-json\/wp\/v2\/comments?post=102"}],"version-history":[{"count":5,"href":"https:\/\/riespw.com\/blog\/wp-json\/wp\/v2\/posts\/102\/revisions"}],"predecessor-version":[{"id":108,"href":"https:\/\/riespw.com\/blog\/wp-json\/wp\/v2\/posts\/102\/revisions\/108"}],"wp:attachment":[{"href":"https:\/\/riespw.com\/blog\/wp-json\/wp\/v2\/media?parent=102"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/riespw.com\/blog\/wp-json\/wp\/v2\/categories?post=102"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/riespw.com\/blog\/wp-json\/wp\/v2\/tags?post=102"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}