I'm trying to plot a histogram of my code but when I run
plot_histogram(results.get_counts(circuit))
it gives me a traceback error.
This is what I had before calling the histogram function:
-result = execute(circuit, backend = simulator).result()
and thereafter when I try to plot it by typing
-plot_histogram(results.get_counts(circuit))
it doesn't work.
results.
when your variable is calledresult
, in which case you should be typingplot_histogram(result.get_counts(circuit))
? $\endgroup$