I have a question regarding paired and unpaired tests. I know the difference between both tests. I am using R for Wilcoxon test. My test is a paired test, however the X and Y do not have the same length and R is giving an error. I do not want/think I should use unpaired test.
For example, I have a subject that makes some cookies every hour. I use some special kind of treatment to increase the stamina. Before the treatment he can only work 4 hours (after day he gets tired) and produces some cookies. After the treatment he produces more cookies per hour and work 7 hours without getting tired.
X contains the number or cookies for each hour before the treatment and Y contains the number of cookies after the treatment. X contains 4 values and Y contains 7 values. Now if I want to use paired test, R gives error.
What should I do? Is there any solution or explanation for such kind of situations? Can I add just NA NA?
"This is just an example please do not point out mistake in the example, it is just to give you an example."
Thank you.
EDIT
Here is basic R script that I use
someData <- read.csv(file="cookie_data.csv",head=TRUE,sep=",")
wilcox.test(someData$X, someData$Y, paired=TRUE)
Sample Data:
X,Y
2,3
3,2
3,3
2,2
,3
,7
,2
When I use this script, R does not give any error. However, when I print someData$X, it prints 4 values and after that it start writing NA NA NA. I noticed R automatically filled blank values with NA. This script gives me p-value but I do not know if it is correct.