# "? Undefined variable lgy\_."

**URL:** <https://forum.dynare.org/t/undefined-variable-lgy-/931>\
**Category:** Dynare v4 (legacy)\
**Created:** [19 February 2009 19:04 UTC](https://forum.dynare.org/t/undefined-variable-lgy-/931 "2009-02-19T19:04:06Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![billsnow](https://forum.dynare.org/letter_avatar_proxy/v4/letter/b/b9e5f3/32.png) [@billsnow](https://forum.dynare.org/u/billsnow)\
**Post date:** [19 February 2009 19:04 UTC](https://forum.dynare.org/t/undefined-variable-lgy-/931/1 "2009-02-19T19:04:06Z")

</div>

When I run the examle file rbc.mod in Dynare 4, it gives me the error message like this:

??? Undefined variable lgy\_.

Error in ==\> rbc\_test at 118  
table(‘Relative standard deviations in %’,strvcat(‘VARIABLE’,‘REL. S.D.’),lgy\_(1:6,:),statistic1,10,8,4);

Error in ==\> dynare at 102  
evalin(‘base’,fname) ;

But it runs well in Dynare 3.

How should I correct this?

Thanks.

Bill

---

<div class="post-metadata">

**Author:** ![sebastien](https://forum.dynare.org/user_avatar/forum.dynare.org/sebastien/32/19973_2.png) [@sebastien](https://forum.dynare.org/u/sebastien)\
**Post date:** [23 February 2009 09:55 UTC](https://forum.dynare.org/t/undefined-variable-lgy-/931/2 "2009-02-23T09:55:39Z")

</div>

Hi,

The “lgy\_” structure is now replaced by “M\_.endo\_names”. Beware that the order of variables may have changed since version 3.

Best,

Sébastien

---

<div class="post-metadata">

**Author:** ![billsnow](https://forum.dynare.org/letter_avatar_proxy/v4/letter/b/b9e5f3/32.png) [@billsnow](https://forum.dynare.org/u/billsnow)\
**Post date:** [23 February 2009 21:26 UTC](https://forum.dynare.org/t/undefined-variable-lgy-/931/3 "2009-02-23T21:26:35Z")

</div>

Thanks, Sébastien.

I got it!!! I have corrected the .m files.

Bill

---

<div class="post-metadata">

**Author:** ![jpfeifer](https://forum.dynare.org/user_avatar/forum.dynare.org/jpfeifer/32/5044_2.png) [@jpfeifer](https://forum.dynare.org/u/jpfeifer)\
**Post date:** [24 July 2017 13:29 UTC](https://forum.dynare.org/t/undefined-variable-lgy-/931/4 "2017-07-24T13:29:00Z")

</div>

Closed on 24 July 2017 13:29 UTC



---

<div class="post-metadata">

**Author:** ![jpfeifer](https://forum.dynare.org/user_avatar/forum.dynare.org/jpfeifer/32/5044_2.png) [@jpfeifer](https://forum.dynare.org/u/jpfeifer)\
**Post date:** [24 July 2017 13:29 UTC](https://forum.dynare.org/t/undefined-variable-lgy-/931/5 "2017-07-24T13:29:47Z")

</div>

Archived on 24 July 2017 13:29 UTC


