Changeset c81dea8 in tol
- Timestamp:
- Nov 23, 2008, 3:04:24 PM (18 years ago)
- Branches:
- 1941-docker-image-to-test, devel, master
- Children:
- 7ddb849
- Parents:
- 9871d4f2
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
tol/stdlib/math/stat/models/bayesian/bysMcmc/bsr/dynhlm/_build.node.obs.tol
r9871d4f2 rc81dea8 36 36 Text _.id_node = id_node; 37 37 Text _.name = name; 38 Real _.isTimeSerie = True; 38 39 Serie _.serie = serie; 39 40 Real _.avg = … … 63 64 //Sorted list of analyzed dates 64 65 Set _.dates = Dates(Dating(_.serie), _.firstIniVal, _.lastDate); 66 Real Get.Equation.Size(Real unused) 67 { 68 Card(_.dates) 69 }; 65 70 Serie _.unk.left = SubSer(CalInd(Dating(_.serie),Dating(_.serie)), 66 71 _.firstIniVal, Succ(First(_.serie),Dating(_.serie),-1)); … … 147 152 Text _.id_node = id_node; 148 153 Text _.name = name; 154 Real _.isTimeSerie = False; 149 155 Matrix _.serie = serie; 150 156 Real _.avg = … … 167 173 { 168 174 Text txt = IntText(num); 169 "MissingBlk::"+_.missing.label+"::"+_.name+"::"+txt 175 "MissingBlk::"+_.missing.label+"::"+_.name+"::N"+txt 176 }; 177 Real Get.Equation.Size(Real unused) 178 { 179 Rows(_.serie) 170 180 }; 171 181 //Returns the expression of the t-th regression coefficient that could be a … … 174 184 { 175 185 //WriteLn("TRACE get.coef t="<<t); 176 Real x = MatDat(_.serie, t );186 Real x = MatDat(_.serie, t, 1); 177 187 If(IsUnknown(x), 178 188 "+"+missing.name(num), … … 182 192 { 183 193 //WriteLn("TRACE get.knownCoefOrAvg t="<<t); 184 Real x = MatDat(_.serie, t );194 Real x = MatDat(_.serie, t,1); 185 195 BysMcmc::Bsr::Import::RealTextS(If(IsUnknown(x),_.avg, x)) 186 196 }; 187 197 //Sorted list of variables related to missing values 188 Set _.missing = EvalSet(Range(1,Rows(_.serie),1),Set(Real num) 189 { 190 Bsr.Missing.Info(Text Name = missing.name(num), 191 Real Average = _.avg, 192 Real Sigma = _.stds*_.missing.sigmaFactor, 193 Real LowerBound = _.missing.lowerBound, 194 Real UpperBound = _.missing.upperBound) 195 }) 198 Set _.missing = 199 { 200 Set aux = EvalSet(Range(1,Rows(_.serie),1),Set(Real num) 201 { 202 Real x = MatDat(_.serie,num,1); 203 If(!IsUnknown(x),Copy(Empty), 204 Bsr.Missing.Info(Text Name = missing.name(num), 205 Real Average = _.avg, 206 Real Sigma = _.stds*_.missing.sigmaFactor, 207 Real LowerBound = _.missing.lowerBound, 208 Real UpperBound = _.missing.upperBound)) 209 }); 210 Select(aux,Card) 211 } 196 212 ]]}; 197 213 … … 503 519 Set Get.TimeInfo(Real unused) 504 520 { 521 If(Not(_.output::_.serie.info::_.isTimeSerie),Copy(Empty), 505 522 BSR.NoiseTimeInfo 506 523 ( … … 508 525 _.output::_.serie.info::_.firstDate, 509 526 _.output::_.serie.info::_.lastDate 510 ) 527 )) 511 528 }; 512 529 Real Get.Equation.Size(Real unused) 513 530 { 514 Card(_.output::_.serie.info::_.dates)531 _.output::_.serie.info::Get.Equation.Size(0) 515 532 }; 516 533 //Returns Real known output or Text missing name
Note: See TracChangeset
for help on using the changeset viewer.
