Added precision argument to print and show functions#148
Added precision argument to print and show functions#148jacobhuesman wants to merge 5 commits intoJuliaControl:masterfrom
Conversation
|
Thanks for the great work, it looks a lot better. One problem is that we switched from our own implementation of polynomials to Polynomials.jl, and partly use that system for printing now. |
|
Oh boy haha... I saw that branch when I was starting on this but figured it would be a while before it was ready to be merged in. I can look into refactoring this later in the week if you think that this functionality is worthwhile to your package. I just picked Formatting.jl since it was readily available. The but that doesn't work well with the |
I added a precision argument to
printandshowto allow for limiting the number of digits displayed by the two functions. Previously for coefficients that didn't come out to be nice numbers, the default number of digits made the output annoying interpret.Here's an example:
Outputting the transfer function to the terminal looked like this:
I added some formatting to make the display a little cleaner:
And adjustable: