It appears that complete figure objects can not be used to set up subplots using make_subplots()
. And as you've shown yourself, fig.add_trace()
can't be used directly with the data from a ff.create_quiver()
figure. What will work though, is to include a unique go.Scatter
for each and every x and y element in fig1.data
:
'x': [0.0, 0.0, None, ..., 1.7591036229552444, 1.7526465527333175, None],
'y': [0.0, 0.0, None, ..., 1.9752925735580753, 1.9216800167812427, None]
That may sound a little complicated, but really isn't at all. Just make two ff.create_quiver() figures
and use this for each of them:
# add all fig1.data as individual traces in fig at row=1, col=1
for d in fig1.data:
subplots.add_trace(go.Scatter(x=d['x'], y=d['y']),
row=1, col=1)
Using the snippet below will produce the following subplot setup with 1 row and two columns. Even the arrow shapes for all lines are included.
Plot

Complete code
import numpy as np
from plotly.subplots import make_subplots
import plotly.graph_objects as go
import plotly.figure_factory as ff
# data
x,y = np.meshgrid(np.arange(0, 2, .2), np.arange(0, 2, .2))
u = np.cos(x)*y
v = np.sin(x)*y
# quiver plots
fig1 = ff.create_quiver(x, y, u, v)
fig2 = ff.create_quiver(x, y, u*0.9, v*1.1)
# subplot setup
subplots = make_subplots(rows=1, cols=2)
# add all fig1.data as individual traces in fig at row=1, col=1
for d in fig1.data:
subplots.add_trace(go.Scatter(x=d['x'], y=d['y']),
row=1, col=1)
# add all fig2.data as individual traces in fig at row=1, col=2
for d in fig1.data:
subplots.add_trace(go.Scatter(x=d['x'], y=d['y']),
row=1, col=2)
subplots.show()