Open mluna11 opened 2 years ago
I had this same problem! I just ignored the first chunk of script (I think it is supposed to be there). Then, to get the coefficient plots, you need to update the code in each model. You will need to replace the b1 and se values, then the plots should come out correctly.
What I did was replace all of the b1 and se plots for each model first, and then I ran the entire code once I was finished. Let me know if that helps!
# replace value with correct b1 and SE for the question
**b1 <- (put b1 here)
se <- (put se here)**
# do not change code below
upper.ci <- b1 + 1.96*se
lower.ci <- b1 - 1.96*se
plot( c(lower.ci,upper.ci), c(1,1),
xlim=c(lower.ci-0.5,1), ylim=c(0,3),
xlab="", ylab="", axes=F, bty="n",
type="l", lwd=3, col="darkorange",
main="Model 2" )
points( b1, 1, col="darkorange", pch=19, cex=3 )
text( b1, 1, b1, pos=3, col="gray30", cex=1.5, offset=1 )
text( c(lower.ci,upper.ci), 1, round(c(lower.ci,upper.ci),2),
pos=c(2,4), cex=0.8, col="gray40")
abline( v=0, lty=2, lwd=2, col="gray40" )
axis( side=1, at=0, labels="B1=0" )
Hello,
I actually think the html output in R is what is supposed to happen. If you look in that code chunk you'll notice it says type = "html". When you knit the RMD file as an html doc it will turn the html output in R studio into the actual visual. R Studio just doesn't turn the html code into visuals within itself, only in the actual html output.
Best, Dylan
Hi,
I can’t get the loaded data to output in R Studio. When it does output, it's in an HTML type format.
When I run the below chunk of script, I get nothing. I believe I'm supposed to get a table as referenced here.
Then when I run this chunk of script:
The output I get looks like this:![Lab 2 Table Output](https://user-images.githubusercontent.com/89233337/131744308-6452820f-1eb3-4eb1-b029-3db5acf6304d.PNG)
Can someone please help me figure out what I'm doing wrong? Is there a package that I need to install to get the tables to load and get them in their correct readable formats?