Black Lives Matter. Please consider donating to Black Girls Code today.
Dash HoloViews is now available! Check out the docs.

Second entry in go.Scatter throw syntax error

Hi,

Could someone please tell me what is wrong with this line of code as it is throwing a syntax error. I have highlighted it in bold. I have checked all the brackets and they do line up. I am just plotting two line graphs on the same chart. When I remove the line, everything is fine.

dcc.Graph(id=‘plot1’,
figure={
‘data’: [go.Scatter(x=MFTdf[‘MFT’], y=MFTdf[‘MFT Planned’], mode = ‘lines’, name = ‘MFT Planned’),
(x=MFTdf[‘MFT’], y=MFTdf[‘MFT Actual’], mode = ‘lines’, name = ‘MFT Actual’)],
‘layout’: go.Layout(title=‘Review States’,
yaxis={‘title’: ‘Completion Status’})}),
dcc.Interval(
id=‘interval-component’,
interval=1*1000, # in milliseconds
n_intervals=0
)

I just looked at the cheat sheet and it must be itemized separately as such.

trace1 = go.Scatter()
trace2 = go.Scatter()

data = [trace1, trace2]

Sorry for wasting everyone’s time.