Dab tsi yog linear regression hauv R programming?
Dab tsi yog linear regression hauv R programming?

Video: Dab tsi yog linear regression hauv R programming?

Video: Dab tsi yog linear regression hauv R programming?
Video: Machine Learning with Python! Train, Test, Split for Evaluating Models 2024, Kaum ib hlis
Anonim

linear regression yog siv los kwv yees tus nqi ntawm qhov sib txawv tsis tu ncua Y raws li ib lossis ntau qhov kev sib piv cov tswv yim sib txawv X. Lub hom phiaj yog los tsim cov qauv lej ntawm cov lus teb sib txawv (Y) thiab qhov ntsuas qhov sib txawv (Xs). Koj tuaj yeem siv cov qauv no los kwv yees Y, thaum tsuas yog X qhov tseem ceeb paub.

Ib yam li ntawd, dab tsi yog regression hauv R programming?

R - Tawm Regression . Kev tshaj tawm. Regression kev tsom xam yog ib qho cuab yeej siv ntau heev los tsim kom muaj kev sib raug zoo ntawm ob qhov sib txawv. Ib qho ntawm cov kev hloov pauv no yog hu ua qhov ntsuas qhov sib txawv uas nws tus nqi tau sau los ntawm kev sim.

Ib sab saum toj no, tus nqi zoo R squared yog dab tsi? R - squared yog ib txwm nyob nruab nrab ntawm 0 thiab 100%: 0% qhia tias tus qauv piav qhia tsis muaj qhov sib txawv ntawm cov ntaub ntawv teb nyob ib puag ncig nws txhais tau tias. 100% qhia tias tus qauv piav qhia txhua qhov sib txawv ntawm cov ntaub ntawv teb nyob ib puag ncig nws txhais tau tias.

Hauv qhov no, dab tsi yog qhov zoo R squared tus nqi rau linear regression?

Rau tib cov ntaub ntawv teev, siab dua R - squared nqi sawv cev me me sib txawv ntawm cov ntaub ntawv pom thiab cov khoom haum tus nqi . R - squared yog qhov feem pua ntawm cov kev hloov pauv hloov pauv uas a kab tawm qauv piav qhia. R - squared yog ib txwm nyob nruab nrab ntawm 0 thiab 100%:

Koj muab cov ntaub ntawv rau hauv R li cas?

Koj ua tau sau cov ntaub ntawv tsuas yog ntaus ntawv hauv qhov tseem ceeb thiab ntaus rov qab los yog tab. Koj tseem tuaj yeem siv cov xub nce thiab nqis los taw qhia. Thaum koj ua tiav, cia li xaiv Cov Ntaub Ntawv> Kaw. Yog tias koj ntaus ls() tam sim no koj yuav tsum pom cov npe sib txawv uas koj tsim.

Pom zoo: