I am trying to plot using plotly offline. It works great, no errors, but I am unable to see any graph. It loads an empty graph! It is working for me in one instance of Jupyter notebook but not in another!
Code:
import pandas as pd
import matplotlib.pyplot as plt
import numpy as np
import re
import requests
import logging
import os
import json
import sys
import bokeh
from ipywidgets import interact
from bokeh.io import push_notebook,show,output_notebook
from bokeh.plotting import figure
import cufflinks as cf
cf.set_config_file(world_readable=True,offline=False)
%matplotlib inline
import seaborn as sns
from plotly.offline import download_plotlyjs,init_notebook_mode,plot,iplot
init_notebook_mode(connected=True)
cf.go_offline()
from plotly.graph_objs import *
import plotly.plotly as py
import plotly.graph_objs as go
trace1 = go.Scatter(
x=[0, 1, 2, 3, 4, 5],
y=[1.5, 1, 1.3, 0.7, 0.8, 0.9]
)
trace2 = go.Scatter(
x=[0, 1, 2, 3, 4, 5],
y=[1, 0.5, 0.7, -1.2, 0.3, 0.4]
)
data = [trace1, trace2]
iplot(data, filename='bar-line')
Result is an empty graph!
