fecon235 icon indicating copy to clipboard operation
fecon235 copied to clipboard

To update pre-2016 notebooks, fix broken import and preamble

Open rsvp opened this issue 9 years ago • 5 comments

Major release v4.15.1230 benefits from the python3 compatibility changes made during v3. All modules are now operational under both Python 2 and 3. Also, code has been rewritten for cross-platform performance (Linux, Mac, and Windows).

We MOVED the yi-modules from nb to a new directory: lib. Python 3 uses absolute import and our python2 code now conforms to that practice.

To update pre-2016 notebooks, please use import style discussed in docs README: https://git.io/fecon-intro The top-level module fecon235.py (formerly known as nb/fecon.py) is also explained in that introduction. With adoption of python3 print_function, the python2 print statement must be rewritten as a function.

We also highly recommend inclusion of PREAMBLE-p6.15.1223 which gives versioning requirements for successful notebook replication. With those fixes, our notebooks should run under both Python kernels in Jupyter, without any dependency on Linux.

rsvp avatar Dec 30 '15 23:12 rsvp

Here's another illustration of "Fix issue #2 with v4 and p6 upgrades": https://git.io/georet which concerns comparative geometric mean returns.

Notice how the import cell precedes the preamble cell in the notebook.

rsvp avatar Jan 06 '16 18:01 rsvp

Git shell script to list commit dates, given path/filename(s)

The system's modification time for a committed file may not be the actual commit date and time! This can be verified
if you checkout an older branch and switch back.

There is no nice builtin git utility, so I wrote one: https://git.io/git-lu and it supports wildcards and shows the short SHA hash ref.

Now we can clearly see which notebooks are actually still pre-2016:

2014-12-07 12:02:38 -0800  362d82c  fred-wage-capital.ipynb
2015-01-17 13:38:57 -0800  1530474  fred-debt-pop.ipynb
2015-01-23 22:46:21 -0800  478e51d  fred-usd-RTB-xau.ipynb
2015-02-03 13:26:13 -0800  2c9b5c2  fred-inflation.ipynb
2015-02-06 08:28:54 -0800  5586678  fred-eurozone.ipynb
2015-03-08 19:15:09 -0700  1d54341  fred-xau-spx.ipynb
2015-05-15 15:29:14 -0700  65f5b40  fred-infl-velocity.ipynb
2015-05-20 11:33:26 -0700  e1f50e1  fred-eur-fx.ipynb

P.S. -- git does not internally keep a record of modification times, just the author date and commit date.

rsvp avatar Aug 13 '17 03:08 rsvp

TODO List

  • [ ] fred-wage-capital.ipynb
  • [x] fred-debt-pop.ipynb
  • [ ] fred-usd-RTB-xau.ipynb
  • [x] fred-inflation.ipynb
  • [ ] fred-eurozone.ipynb
  • [ ] fred-xau-spx.ipynb
  • [ ] fred-infl-velocity.ipynb
  • [ ] fred-eur-fx.ipynb

rsvp avatar Nov 14 '17 08:11 rsvp

Fixed fred-inflation.ipynb, but there's more notebooks to revise. Reopen issue.

rsvp avatar Mar 07 '18 19:03 rsvp

CHANGELOG 2018-06-23 (tag: v6.18.0623)

Major version change for fecon235 from v5 to v6 signaling our integration with fecon236 which was spun-off from our source code.

Henceforth, fecon235 becomes a repository solely of Jupyter notebooks. The old Python source code at fecon235 will remain for archival purposes, while new code development shifts over to fecon236. Please see https://git.io/econ for details.

Revise docs/fecon235-00-README.ipynb to introduce fecon236. Function names have been retained, but under fecon236 the call routing is expected to be more explicit than casual, i.e. modules names are more significant. Please see https://git.io/fecon-intro

Recommended import style

import fecon236 as fe

Function names have been retained, but under fecon236, expect infrequent function calls to be explicit rather than implicit, i.e. modules names and their aliases are significant.

rsvp avatar Jun 25 '18 17:06 rsvp