Changeset 823054d in tol for tol_tests


Ignore:
Timestamp:
Apr 14, 2010, 3:52:59 PM (17 years ago)
Author:
Víctor de Buen <vdebuen@…>
Branches:
1941-docker-image-to-test, devel, master
Children:
ece8aea
Parents:
f9c7f71
Message:

_.k y _.s se modifican para mantener el ratio de aceptación dentro de un rango dado

git-svn-id: ​https://www.tol-project.org/svn/tolp/trunk@2100 be4846ae-f051-483a-831f-b64e7d08527f

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tol_tests/tol/ARIMA/mcmc/MTryMetropolis.tol

    rf9c7f71 r823054d  
    9797    Real _.acceptRatio := _.num_accept / _.num_draw;
    9898    Real Case(
     99    _.acceptRatio<0.50,
     100    {
     101      If(_.k<_.n,    _.k := _.k+1);
     102      If(_.s>1.E-3,  _.s := _.s/_.sFactor)
     103    },
     104    _.acceptRatio>0.75,
     105    {
     106      If(_.k>1,     Real _.k := _.k-1);
     107      If(_.s<1.E+3, Real _.s := _.s*_.sFactor)
     108    });
     109
     110/*
     111    Real Case(
     112    _.k>1, { False },
    99113    _.acceptRatio<_.acceptRatioTarget/1.01,
    100114    {
    … …  
    105119      Real _.s := _.s*_.sFactor
    106120    });
     121*/
    107122  //Real If(_.accept, { Real doAfterDraw(0) });
    108123    Real doAfterDraw(0);
Note: See TracChangeset for help on using the changeset viewer.