Comments (6)
Outside of IPython notebooks, you can zoom-in, pan, etc. in Matplotlib plots. I just shared a link via issue #49 to matplotlib.backend_bases.MouseEvent for responding to clicks on points in these plots.
Perhaps there can be two major interactive use-cases: with and without IPython. The former case could be treated with Bokeh, and the latter case with Matplotlib and various GUI hooks that we create.
from python-control.
Clancy,
I use the following code in my ipython notebooks and it makes the plots
interactive (zooming, panning work; this is in the standard Anaconda
distribution on OSX 10.10):
import matplotlib as mlt
mlt.use('nbagg') # makes plots interactive for zooming.
I haven't tested it with python-control yet but I don't see why there would
be a problem.
- Sawyer
Sawyer B. Fuller, Ph.D.
Harvard School of Engineering and Applied Science
Wyss Institute for Biologically Inspired Engineering
http://people.seas.harvard.edu/~minster/
On Fri, Mar 20, 2015 at 1:55 PM, Clancy Rowley [email protected]
wrote:
I find IPython notebooks a great way to work interactively, and it would
be nice if inline plots could be interactive (e.g., letting you zoom, or
having tool tips show more information). With matplotlib, though, inline
plots are just images, so they cannot be interactive.There's a new plotting library called Bokeh http://bokeh.pydata.org, an
open-source project led by Continuum Analytics (the wonderful folks that
make Anaconda http://continuum.io/downloads), that looks really nice
for making interactive plots like this. I'd like to try making an alternate
backend one could specify with, say, control.set_backend("bokeh") that
would make commands like bode() and nyquist() generate plots using Bokeh.
The default could still be matplotlib, of course.Any thoughts or suggestions for other libraries that might be useful for
making interactive plots?Reply to this email directly or view it on GitHub
#50.
from python-control.
@blinkminster, that is pretty slick! I never new about nbagg. (Incidentally, this also apparently works with the IPython magic %matplotlib nbagg
.) I still might give the Bokeh library a try, but this is great to know about.
from python-control.
I am also wondering about this issue for my library and I have been also trying to find a good basis for this issue. So far I've been experimenting with Bokeh. Things are still wonky as an experiment but I just wanted to also get your opinion about the following prototype
http://nbviewer.jupyter.org/gist/ilayn/f8cf8b0a68c6839dbcc346884511e2ed
There are some issues of course since I'm still learning JS magic but I guess it might serve as a basis. Though I don't follow the same structure as python-control the data will come from somewhere anyway for frequency responses. Hence, from the point on where one has the complex number array this can be used independently. Maybe python-control devs can use this and put more momentum to this kind of development?
from python-control.
See PR #204 and #209 for some initial implementations of this type of functionality.
from python-control.
Hello,
I teach control systems. I recently created an interactive interface with Bokeh for using in Google Colab similar to Sisotool (Matlab): https://github.com/lucasbellinaso/PythonSisoDesignApp
Still needs improvement.
from python-control.
Related Issues (20)
- How to convert finite step response model to state space representation? HOT 2
- Output calcs produce 0's at every other call HOT 2
- equations not showing up correctly in online docs HOT 2
- Interconnect function strange behavior HOT 3
- TypeError: No support for MIMO without slycot HOT 4
- TimeResponseData.to_pandas() fails if there are no states in a NonlinearIOSystem HOT 1
- plotting example mimo system HOT 1
- Display Connection Matrix HOT 8
- (accidentally opened issue with garbage title) HOT 1
- Observability Gramian for discrete-time systems HOT 8
- `phase_plot` ODE function signature is not compatible with `solve_ivp` and `StateSpace.dynamics` HOT 2
- Strange nondeterministic issues when using `phase_plot` with `X`, `Y` and `X0` set HOT 1
- `control.mixsyn` hangs on M1 HOT 2
- Scaling for control.impulse_response discrete time is not correct HOT 6
- documentation out of date HOT 1
- Wrong parameter name in documentation HOT 1
- Parallel system interconnection using `control.interconnect()` HOT 4
- Plotting nyquist plot from FrequencyResponseData fails HOT 3
- forced_response giving different output depending on Python and/or numpy version HOT 9
- inconsistent kwarg klist/kvect/gains in rlocus doc HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from python-control.