Scilab 5.3.0
- Scilab Online Help
- CACSD
- abcd
- abinv
- arhnk
- arl2
- arma
- arma2p
- armac
- armax
- armax1
- arsimul
- augment
- balreal
- bilin
- black
- bode
- bstap
- cainv
- calfrq
- canon
- ccontrg
- chart
- cls2dls
- colinout
- colregul
- cont_frm
- cont_mat
- contr
- contrss
- copfac
- csim
- ctr_gram
- dbphi
- dcf
- ddp
- des2ss
- des2tf
- dhinf
- dhnorm
- dscr
- dsimul
- dt_ility
- dtsi
- equil
- equil1
- evans
- feedback
- findABCD
- findAC
- findBD
- findBDK
- findR
- findx0BD
- flts
- fourplan
- frep2tf
- freq
- freson
- fspecg
- fstabst
- g_margin
- gainplot
- gamitg
- gcare
- gfare
- gfrancis
- gtild
- h2norm
- h_cl
- h_inf
- h_inf_st
- h_norm
- hallchart
- hankelsv
- hinf
- imrep2ss
- inistate
- invsyslin
- kpure
- krac2
- lcf
- leqr
- lft
- lin
- linf
- linfn
- linmeq
- lqe
- lqg
- lqg2stan
- lqg_ltr
- lqr
- ltitr
- m_circle
- macglov
- markp2ss
- minreal
- minss
- mucomp
- narsimul
- nehari
- nicholschart
- noisegen
- nyquist
- obs_gram
- obscont
- observer
- obsv_mat
- obsvss
- p_margin
- parrot
- pfss
- phasemag
- ppol
- prbs_a
- projsl
- reglin
- repfreq
- ric_desc
- ricc
- riccati
- routh_t
- rowinout
- rowregul
- rtitr
- sensi
- sgrid
- show_margins
- sident
- sm2des
- sm2ss
- sorder
- specfact
- ss2des
- ss2ss
- ss2tf
- st_ility
- stabil
- svplot
- sysfact
- syssize
- tf2des
- tf2ss
- time_id
- trzeros
- ui_observer
- unobs
- zeropen
- zgrid
Please note that the recommended version of Scilab is 2025.0.0. This page might be outdated.
See the recommended documentation of this function
reglin
線形回帰
C呼び出し手順
[a,b,sig]=reglin(x,y)
説明
最小二乗解として回帰問題y=a*x+ bを解きます.
sig
は残差の標準偏差です.
x
および y
は大きさ x(p,n)
および y(q,n)
の行列, ただしn
はサンプル数,です.
推定器 a
は大きさ (q,p)
の行列,
b
は大きさ
(q,1)
のベクトルです.
// simulation of data for a(3,5) and b(3,1) x=rand(5,100); aa=testmatrix('magi',5);aa=aa(1:3,:); bb=[9;10;11] y=aa*x +bb*ones(1,100)+ 0.1*rand(3,100); // identification [a,b,sig]=reglin(x,y); maxi(abs(aa-a)) maxi(abs(bb-b)) // an other example : fitting a polynom f=1:100; x=[f.*f; f]; y= [ 2,3]*x+ 10*ones(f) + 0.1*rand(f); [a,b]=reglin(x,y)
<< projsl | CACSD | repfreq >> |