Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

deactivate broken features from bodeplot #667

Merged
merged 1 commit into from
Mar 11, 2022
Merged

deactivate broken features from bodeplot #667

merged 1 commit into from
Mar 11, 2022

Conversation

baggepinnen
Copy link
Member

This PR deactivates a lot of the "smart features" in the bodeplot since they are broken in too many cases.

The biggest problem is that if bodeplot is invoked twice, the second invocation overrides everything that was set during the first invocation. This causes x/y-ticks to be garbage and overrides user set titles and labels. Also, the automatic label G_1(s) does not increase the subscript number unless bodeplot is invoked once only, causing multiple systems to get the same label.

I have tried for a while to fix the problems, but it requires making use of a lot of internals and I didn't manage to get a robust solution. If anyone wants to commit to implementing and maintaining a really solid and robust solution that works for all backends, I'd be up for that, otherwise I say we ditch all the broken code.

@JuliaControlBot
Copy link

This is an automated message.
Plots were compared to references. 7/11 images have changed, see differences below.
After pulling this PR, please update the reference images by creating a PR to ControlExamplePlots.jl here.

Difference Reference Image New Image
❌ 0.048 Reference New
✔️ 0.001 Reference New
✔️ 0.001 Reference New
✔️ 0.0 Reference New
❌ 0.043 Reference New
❌ 0.046 Reference New
✔️ 0.01 Reference New

@codecov
Copy link

codecov bot commented Mar 11, 2022

Codecov Report

Merging #667 (31331c0) into master (becef5c) will increase coverage by 0.17%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #667      +/-   ##
==========================================
+ Coverage   86.75%   86.92%   +0.17%     
==========================================
  Files          31       31              
  Lines        3360     3305      -55     
==========================================
- Hits         2915     2873      -42     
+ Misses        445      432      -13     
Impacted Files Coverage Δ
src/plotting.jl 86.79% <ø> (+1.19%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update becef5c...31331c0. Read the comment docs.

Copy link
Member

@albheim albheim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't say I really like some of the defaults after this change, e.g. y1 and y2 labels in mag resp phase for a single curve, but then there were some problematic default before also. And it is not really that much of a problem to send in some keywords from the user side if one wants something more specific in the label.

I think it seems like a reasonable step to take. If anyone wants to specify a lot of stuff it is probably less chance we have overridden something to make that problematic, and for just quick plots we have all basic information that is needed in a format that is good enough.

@baggepinnen
Copy link
Member Author

baggepinnen commented Mar 11, 2022

Yeah, the y1 default label Plots uses feels rather arbitrary, but then again, it's the same for every kind of plot using Plots :/
I do however prefer y1, y2 to G1, G1 :P

@baggepinnen baggepinnen merged commit 44f380f into master Mar 11, 2022
@baggepinnen baggepinnen deleted the brokenbode branch March 11, 2022 12:08
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.

3 participants