Displaying 2 results from an estimated 2 matches for "topshelf".
Did you mean:
conshelf
2023 May 18
1
suprising behaviour of tryCatch()
...reated for and used by `fun` subject to the rules
of argument matching.
These are very different (see documentation/tutorials on variable
scoping if you do not already understand how different these are).
As a simple analogy, think of a function like the refrigerator in your house.
refrigerator( topshelf = bottle ) will put the bottle on the top
shelf inside of the refrigerator
refrigerator( topshelf <- bottle ) will put the bottle on the top
shelf in the same room that the refrigerator is in (but not in the
fridge itself)
When you run the code with `<-` it, then the ith element of the glo...
2023 May 17
4
suprising behaviour of tryCatch()
Hello,
I run a fisher.test() in a loop, with the issue that some of the data will not be useable. To protect the loop I used tryCatch but:
sexsnp = rep(NA, 1750)
for(i in 1:1750){tryCatch(sexsnp[i] = fisher.test(table(data[,3], data[,i + 38]))$p, error = function(e) print(NA))}
Error: unexpected '=' in "for(i in 1:1750){tryCatch(sexsnp[i] ="
But this works:
for(i in