Given
p<-function(x){if ( x==-4) {
0.1
} else if (x==-1 ) {
0.2
} else if ( x==1) {
0.6
} else if (x==2 ) {
0.1
} else {
0
}
How would I plot the PMF and CDF. No distribution is specified so I cant use the build in commands. What would be the best way to plot these