Re: [R] Plotting in R

2019-07-11 Thread Jim Lemon
Hi Steven, Neat solution. With a lot more values on the time axis, you will be better off with something like: yrticks<-as.Date(as.character(seq(min(sydf$year1),max(sydf$year1),by=2)), "%Y") axis(1,at=yrticks,labels=format(yrticks,"%Y")) You probably won't need staxlab for that. Jim On Fri,

Re: [R] Plotting in R

2019-07-11 Thread nstefi
Thanks Jim, that worked. > I expected that the axis labels would be crowded so I used the plotrix > library to stagger the x-axis labels. Hope this solves your problem. I liked how that showed, not overlapping on each other. I wasn't aware of the plotrix library. In my code I was using plot_ly

Re: [R] Plotting in R

2019-07-11 Thread Jim Lemon
Hi Steven, It is pretty easy, but there are one or two things to watch for. First, don't use a hyphen in a field name unless you enclose it in single quotes when extracting it. I've just removed the hyphen in this example: sydf<-read.table(text="year1 monthday rate 1993 05-01 0.608 1994 06-01

Re: [R] mirt-simdata question.

2019-07-11 Thread Abby Spurdle
I don't understand your question. > I am simulating multi-dimensional and categorical items What do you mean by "and"? Reading this sentence alone, I would assume you want one simulated dataset that's categorical and multivariate. Which is easy to do... Because (in general) you can simulate

Re: [R] mirt-simdata question.

2019-07-11 Thread Suna Paek
Hi. Again. I still cannot understand that why the simulated categories have opposite of normal distribution. Theta is set as normal function. Then, more obs. should have more proportion of middle categories. But, all items of simulated data have the most probabilities at the least ability

Re: [R] mirt-simdata question.

2019-07-11 Thread Suna Paek
Thank you for answering. I know mirt is not related the distribution of categories. My study is factor analysis results difference of limited information methods and full information methods. I need a simulation data to compare those. And limited information factor analysis need an assumption of

Re: [R] Plotting in R

2019-07-11 Thread Bert Gunter
?axis -- And note the examples! *Please* go through one or more of the web tutorials on plotting in R. I feel that it is unfair of you to ask for such basic tutorials here when resources are already available to you (others may disagree, of course). If you have questions *after* reading, then

Re: [R] Plotting in R

2019-07-11 Thread David Carlson
There's a typo in the first column name of your data - "year1" should be "year". Sometimes R will do partial matching and find it, but not always. Is this closer to what you're looking for? plot(rate~year, sydf, type="b", xaxt="n", xlab="Month-Day") axis(1, sydf$year, sydf$month.day) This will

Re: [R] Plotting in R

2019-07-11 Thread nstefi
Sorry Jim, I saw that you answered to the other Steven. I had a question and nobody responded to that yet, I thought you responded to me. I searched for mine and your email came up, but I realize the subject line is different. My question was: "How to change x axes labels in plot_ly?"

Re: [R] Plotting in R

2019-07-11 Thread nstefi
Hi Jim, Thanks for your email. My question was: how to change the x axis labels without changing the chart. Or is that not possible? Using your example, I added another column: sydf<-read.table(text="year1 month-day rate 1993 05-01 0.608 1994 06-01 0.622 1996 07-01 0.623 1998 08-01 0.647

Re: [R] mirt-simdata question.

2019-07-11 Thread Doran, Harold
You're asking a question unrelated to R programming and so you won't get a useful response here. However, your question also suggests a misunderstanding of IRT. Generating multi-dimensional data involves generating ability estimates with additional nuisance dimensions and that has no

Re: [R] mirt-simdata question.

2019-07-11 Thread Suna Paek
Hi. again. Still the same problem, but I made a new code to see better of my question. Like the first email, I still want each item's categories to have a normal distribution. it doesn't have to statistically fit. I made 2 different code. And, I found if the histogram is the opposite, they will

Re: [R] mirt-simdata question.

2019-07-11 Thread Suna Paek
Hi. I always thank you all of the R program worker and researchers. I am using R for my thesis, and I have a question. I am simulating multi-dimensional and categorical items (polytomous) with mirt-simdata. However, I wish each items' categories are normal distribution. I checked a lot of

[R] Curious about pairwise limits with cov()

2019-07-11 Thread Doran, Harold
The help for cov() clearly notes that pairwise only works with pearson. I'm curious why as it is surely not computational. Certainly an analyst knows the nature of the missingness in their data and if it's not MCAR then applying pairwise to spearman would have the same inferential consequence