plotprobs {QuantumOps}R Documentation

plotprobs

Description

Plots the probabilities of each of the amplitudes of ket in a barplot

Usage

plotprobs(v,color=rep("Blue",length(v)),customLegend=FALSE,lgNm="",lgCl="")

Arguments

v

ket that is to be plotted

color

Text, possibly an array, specifying the colors of the bars

customLegend

Boolean specifying if a custom legend should be inserted

lgNm

Vector of legend names

lgCl

Vector of legend colors

Value

A plot

Examples

 plotprobs(ket(1,0,1,0),color=c("Red","Blue","Red","Blue"))

[Package QuantumOps version 3.0.1 Index]