So for the code below i made my own scatterplot matrix-ish with just `matplotlib`

before i found `plotly`

. So while changing it over to `plotly`

I found that I was not getting the same results for my plot (`matplotlib`

) and plot2 (`plotly`

) matrices. For some reason the `plotly`

one was taking every scatterplot and showing it twice.I have images posted below of how they showed up. Like even `x_2`

and `x_2`

should be a straight line but it its not. That line finally appears after all of the repetition at `x_3`

x `x_3`

.

I was wondering if anyone has had this issue or if they know how to fix it?

```
import matplotlib.pyplot as plt
import plotly.offline as py
import plotly.figure_factory as ff
import numpy as np
import pandas as pd
def generate(mean, cov, num):
re = list()
for i in range(num):
re.append(np.random.multivariate_normal(mean, cov).T)
return re
def plot(vectors):
x_ = [[] for x in range(len(vectors[0]))]
for v in vectors:
for i in range(0, len(v)):
x_[i].append(v[i])
for i in range(0, len(x_)):
for j in range(0, len(x_)):
#if i == j: continue
plt.ylabel('x_' + str(j))
plt.xlabel('x_' + str(i))
plt.plot(x_[i], x_[j], 'ro')
plt.savefig('./img/2/{}x{}.png'.format(i,j), bbox_inches='tight')
plt.close()
def plot2(data):
df = pd.DataFrame(data, columns=['x_1', 'x_2', 'x_3'])
fig = ff.create_scatterplotmatrix(df, height=1200, width=1200,
marker = dict(
opacity = .5,
),
)
py.plot(fig, filename='2.html')
numVectors = 100
mean = np.array([1, 2, 1])
cov = ([[4, .8, -.3],
[0.8, 2, .6],
[-.3, .6, 5]])
gen_vec = generate(mean, cov, numVectors)
plot(gen_vec)
plot2(gen_vec)
```