Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

make `%matplotlib widget` behave like `inline`?

Abierto
#171 11 comentarios 10 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
5/5
Tiempo estimado
Más de una semana
Aptitud para principiantes
25/100
Tipo de issue
Nueva funcionalidad
Claridad
Necesita aclaración
Estado de actividad
Estancado
Stack tecnológico
jupyter, jupyter-notebook

Línea de trabajo

Comienza reproduciendo el comportamiento en Jupyter Lab con %matplotlib widget, comandos de trazado secuenciales y @interact; después, compáralo con el inline backend predeterminado. Determina si se pueden admitir la salida limitada a la celda solicitada y la interacción con actualización; se considera terminado cuando se documente un enfoque compatible o se identifique claramente el cambio de comportamiento necesario.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

I have a notebook in Jupyter Lab, so far using the default matplotlib backend, which in this context I believe is inline. When I have a sequence of plotting commands (pyplot.plt etc.), they combine into a figure that is shown after the respective code cell. Also, @interact works as expected.

I now wanted to zoom in, which inline does not support, so I issued %matplotlib widget. The figures are now zoomable alright, but I don't have that neat behavior where plotting code in one cell contributed to the following figure output cell, and doesn't modify anything else. And @interact, instead of producing new (versions of) a figure, now puts everything on top of each other.

From reading around I realize that this is the intended behavior. The thing is, I don't like it. So my question is: Is there a way to make widget behave like inline?

If there is not, is there a guide that tells me how to modify my code so that plot commands affect only the next output cell, and @interact updates instead of adds?

Lenguaje dominante
Jupyter Notebook
Estrellas
1.7k
Forks
234
Métricas de merge de PR
Sin PR fusionados en 30 d

Guía de contribución

Abrir la guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de matplotlib/ipympl

Todos los issues de matplotlib/ipympl

Issues similares

Más issues de DevTools

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.