Skip to content

ENH: added formatting to iteration printing#124

Merged
sglyon merged 3 commits intomasterfrom
fp_printing
Mar 19, 2015
Merged

ENH: added formatting to iteration printing#124
sglyon merged 3 commits intomasterfrom
fp_printing

Conversation

@sglyon
Copy link
Copy Markdown
Member

@sglyon sglyon commented Feb 13, 2015

This adds a bit prettier printing scheme to compute fixed point.

It might belong somewhere else in the project as it can be used in any iterative algorithm.

Perhaps we should lump this and @albop's timer code into a util.py file or something similar?

@coveralls
Copy link
Copy Markdown

Coverage Status

Coverage remained the same at 91.21% when pulling a3863f7 on fp_printing into 5e70cc8 on master.

This avoids conflict with the python builtin `iter`
@albop
Copy link
Copy Markdown
Contributor

albop commented Feb 13, 2015

@spencerlyon2: which timer code are you refering to ? Is it related to the discussion we had a while ago EconForge/dolo.py#34 about adding a time decorator for time consuming functions ? If so, I don't like that idea anymore: it makes more sense to use a context manager for that. I guess it would fit perfectly in quantecon. I'm opening an issue for that.

@sglyon
Copy link
Copy Markdown
Member Author

sglyon commented Feb 13, 2015

@albop I was talking about this code: https://github.com/QuantEcon/QuantEcon.py/blob/master/quantecon/timing.py

Although the watcher seems quite cool

@coveralls
Copy link
Copy Markdown

Coverage Status

Coverage remained the same at 91.21% when pulling 7b56c25 on fp_printing into 5e70cc8 on master.

@jstac
Copy link
Copy Markdown
Contributor

jstac commented Feb 14, 2015

@spencerlyon2 This is nice. The function compute_fixed_point is already quite generic and can be used by lots of routines. My two cents is that it's good where it is.

Shall we leave it where it is for now with the option of pulling it out and putting it in a util.py file in the future should demand arise?

@albop
Copy link
Copy Markdown
Contributor

albop commented Feb 14, 2015

Ahem, that was out of topic: I had forgotten about the tic-tac-toc routines.
As for relocating code, I don't have any position, except a small dislike for long files. The status quo seems fine.

sglyon added a commit that referenced this pull request Mar 19, 2015
ENH: added formatting to iteration printing
@sglyon sglyon merged commit 4511448 into master Mar 19, 2015
@sglyon sglyon deleted the fp_printing branch March 19, 2015 00:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants