Lines Matching full:self
45 my $self = shift;
47 $self->{n} = 0;
48 $self->{sx} = 0.0;
49 $self->{sx2} = 0.0;
50 $self->{sxy} = 0.0;
51 $self->{sy} = 0.0;
52 $self->{sy2} = 0.0;
57 my $self = shift;
60 ++($self->{n});
61 $self->{sx} += $_x;
62 $self->{sy} += $_y;
63 $self->{sxy} += $_x * $_y;
64 $self->{sx2} += $_x**2;
65 $self->{sy2} += $_y**2;
70 my $self = shift;
72 return 1 unless ($self->{n} * $self->{sx2} - $self->{sx}**2);
73 return ($self->{n} * $self->{sxy} - $self->{sx} * $self->{sy})
74 / ($self->{n} * $self->{sx2} - $self->{sx}**2);
79 my $self = shift;
81 return ($self->{sy} - B() * $self->{sx}) / $self->{n};
86 my $self = shift;
93 my $self = shift;
100 my $self = shift;
102 my $s = ($self->{n} * $self->{sx2} - $self->{sx}**2)
103 * ($self->{n} * $self->{sy2} - $self->{sy}**2);
107 return ($self->{n} * $self->{sxy} - $self->{sx} * $self->{sy}) / sqrt($s);
112 my $self = shift;
114 return ($self->{sxy} - $self->{sx} * $self->{sy} / $self->{n})
115 / ($self->{n} - 1);
120 my $self = shift;
122 return 0 if $self->{n} <= 1;
123 return sqrt(($self->{sy2} - ($self->{sy} * $self->{sy}) / $self->{n})
124 / ($self->{n}));
129 my $self = shift;
131 return 0 if $self->{n} <= 0;
132 return $self->{sy} / $self->{n};
138 my $self = {
146 bless $self, $class;
147 init($self);
148 return $self;