tag:blogger.com,1999:blog-6715598735361401237.comments2023-07-23T13:34:48.842+02:00Gregor Gorjanc (gg)Gorjanc Gregorhttp://www.blogger.com/profile/07815994784120702971noreply@blogger.comBlogger264125tag:blogger.com,1999:blog-6715598735361401237.post-63423093943533423542022-11-12T12:24:04.486+01:002022-11-12T12:24:04.486+01:00We could probably cut out the first part by alloca...We could probably cut out the first part by allocating an empty data.frame and run just the loop!Gorjanc Gregorhttps://www.blogger.com/profile/07815994784120702971noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-75168382053522122252022-04-19T23:55:46.826+02:002022-04-19T23:55:46.826+02:00Sorry, but the site is not maintained anymore.Sorry, but the site is not maintained anymore.Gorjanc Gregorhttps://www.blogger.com/profile/07815994784120702971noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-25398289532604895402022-04-19T11:30:30.883+02:002022-04-19T11:30:30.883+02:00Respected Gregor sir, Namaste !
I'm Chirag a ...Respected Gregor sir, Namaste !<br /><br />I'm Chirag a PhD Scholar in Animal Genetics and Breeding at the Indian veterinary research institute, India. <br /><br />Sir, I have read many research papers of yours and follow you on Twitter and various platforms.<br /><br />Sir, while reading about your breeding work and in search of material for advanced animal breeding I came to know about the animal breeding and genetics hub website. Where, some study material was available.<br />here is the link that was previously accessible<br />http://www.netvibes.com/ABG-Hub#General<br /><br />Sir, now that link is not working and after clicking on that, it leads me to somewhere else.<br /><br />sir, as you have mentioned about "ABG Hub". <br />kindly provide me with a link to "ABG Hub" I will be so much thankful to you.<br /><br />Sir, one more to request you to provide me a Animal breeding and genetics study material that you have.<br /><br />Yours sincerely and obedient student,<br />Chirag<br />drcpvetrpur2015@gmail.com <br />Chiraghttps://www.blogger.com/profile/12040607428611651911noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-16923226902561872752022-02-06T08:25:08.811+01:002022-02-06T08:25:08.811+01:00i think you can use pluck() for a cleaner syntax. ...i think you can use pluck() for a cleaner syntax. i had a similar issue and found this:<br />https://rstudio-education.github.io/tidyverse-cookbook/transform-lists-and-vectors.html#extractAnonymousnoreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-6324503473638156122021-02-16T09:49:49.457+01:002021-02-16T09:49:49.457+01:00thank you very much boruthank you very much <a href="https://www.dizayngrup.com/" rel="nofollow">boru</a>boruhttps://www.dizayngrup.comnoreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-65363270897246455812020-07-22T01:29:37.588+02:002020-07-22T01:29:37.588+02:00to make the list even more complete:
https://stack...to make the list even more complete:<br />https://stackoverflow.com/questions/12946883/strsplit-by-row-and-distribute-results-by-column-in-data-framesilurushttps://www.blogger.com/profile/08134750001420159679noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-32465249305917924712019-03-20T04:05:25.666+01:002019-03-20T04:05:25.666+01:00convert csv, markdown table, excel, html to latex ...convert csv, markdown table, excel, html to latex table online: <a href="https://tableconvert.com" rel="nofollow">https://tableconvert.com</a>Ayayohttps://tableconvert.comnoreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-58552632968557298242018-12-18T11:08:35.522+01:002018-12-18T11:08:35.522+01:00You made an article that is interesting. You made an article that is interesting. Kate Lynchhttps://www.clippingpathquick.com/noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-10648111879366391042018-04-23T13:22:16.601+02:002018-04-23T13:22:16.601+02:00Lineage: Visualizing Multivariate Clinical Data in...Lineage: Visualizing Multivariate Clinical Data in Genealogy Graphs<br />https://www.biorxiv.org/content/biorxiv/early/2018/02/27/128579.full.pdfGorjanc Gregorhttps://www.blogger.com/profile/07815994784120702971noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-38477092404395085122018-03-16T22:38:35.125+01:002018-03-16T22:38:35.125+01:00The modified scripted as below works just fine on ...The modified scripted as below works just fine on my rstudio:<br />```<br />library(package="MatrixModels")<br /><br />dat <- data.frame( y=c(1.5, 2.35, 3.4, 2.31, 1.53),<br /> s1=c("AA", "Aa", "Aa", "AA", "aa"),<br /> s2=c("Bb", "BB", "bb", "BB", "bb"),<br /> s3=c("cc", "Cc", "Cc", "cc", "CC"),<br /> s4=c("Dd", "Dd", "DD", "dd", "Dd"))<br /><br />cols <- paste("s", 1:4, sep="")<br />dat[, cols] <- lapply(dat[, cols], function(z) as.integer(z) - 1)<br /><br />lambda <- 1<br /><br />dat<br />(y <- dat$y)<br />(X <- as.matrix(model.Matrix(y ~ 1, data=dat, sparse=TRUE)))<br />(Z <- as.matrix(model.Matrix(y ~ -1 + s1 + s2 + s3 + s4, data=dat, sparse=TRUE)))<br /><br />XX <- crossprod(X)<br />XZ <- crossprod(X, Z)<br />ZZ <- crossprod(Z)<br /><br />Xy <- crossprod(X, y)<br />Zy <- crossprod(Z, y)<br /><br />(LHS <- rbind(cbind(XX, XZ),<br /> cbind(t(XZ), ZZ + diag(dim(ZZ)[1]) * lambda)))<br /><br />(RHS <- rbind(Xy,<br /> Zy))<br /><br />(sol <- solve(LHS, RHS))<br /><br />(GEBV <- Z %*% sol[-1])<br />```Anonymoushttps://www.blogger.com/profile/00345683984052007096noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-64822679890622173722018-03-16T22:12:01.402+01:002018-03-16T22:12:01.402+01:00XX <- crossprod(X)
gives me
Error in crossprod...XX <- crossprod(X)<br />gives me <br />Error in crossprod(x, y) : <br /> requires numeric/complex matrix/vector argumentsAnonymoushttps://www.blogger.com/profile/00345683984052007096noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-2189259191848406712018-02-23T13:14:36.523+01:002018-02-23T13:14:36.523+01:00Thanks for the tip on using Sweaveinput instead of...Thanks for the tip on using Sweaveinput instead of include, that was just what I needed.Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-55830545111057163042018-01-15T23:19:45.505+01:002018-01-15T23:19:45.505+01:00wc is a UNIX/Linux command that counts the number ...wc is a UNIX/Linux command that counts the number of words and/or lines in a file. You could modify the code so that it does not really on this utility.Gorjanc Gregorhttps://www.blogger.com/profile/07815994784120702971noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-24682662696079500672018-01-15T22:42:26.568+01:002018-01-15T22:42:26.568+01:00Gave it a try with my text file but got this error...Gave it a try with my text file but got this error<br /><br />"Error in system(command = com, intern = TRUE) : 'wc' not found"Anonymoushttps://www.blogger.com/profile/05826257880158579845noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-75517657540356262552017-03-06T08:32:03.381+01:002017-03-06T08:32:03.381+01:00Thanks Gregor. Good diagram of your user experienc...Thanks Gregor. Good diagram of your user experience and the answer helped me as well.isomorphismeshttp://r.isomorphism.esnoreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-60681308162358399722016-06-17T06:19:54.400+02:002016-06-17T06:19:54.400+02:00Just keep increasing the limits until you solve th...Just keep increasing the limits until you solve the problem or hit the wall.Gorjanc Gregorhttps://www.blogger.com/profile/07815994784120702971noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-24483023761095108752016-06-16T21:38:46.641+02:002016-06-16T21:38:46.641+02:00Great. But how you determined how much memory is n...Great. But how you determined how much memory is needed, since your vector was from 130.4 mb?Ashleyhttps://www.blogger.com/profile/07155584992370323625noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-21198246949285437722016-04-07T10:15:55.437+02:002016-04-07T10:15:55.437+02:00Hi,
In R it is also possible to draw a pedigree wi...Hi,<br />In R it is also possible to draw a pedigree with pedantics package. With your example, this would be :<br /> library(pedantics)<br /> frame() #to make empty plot first<br /> colnames(ped) <- c("id", "sire", "dam", "sex", "aff")<br /> drawPedigree(ped[,c("id", "dam", "sire")],sex=ped$sex, sexInd = c(1,2), dots='y',dotSize=0.005) <br /><br />This is not nice but it works even if you only know one parent for some individuals, if you have many individuals without known sex, or if you have individuals used as males and females (like in plant species).<br /><br />Without R I used pedimap (http://www.ncbi.nlm.nih.gov/pubmed/23087384).Anonymoushttps://www.blogger.com/profile/05821527407658745926noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-3375262004282013502015-09-11T13:32:10.632+02:002015-09-11T13:32:10.632+02:00Why don't you simply use all 500 SNP markers?Why don't you simply use all 500 SNP markers?<br />Gorjanc Gregorhttps://www.blogger.com/profile/07815994784120702971noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-60963639477626501412015-09-11T10:38:55.263+02:002015-09-11T10:38:55.263+02:00Hi Gregor! I'm new to breeding concepts. I hav...Hi Gregor! I'm new to breeding concepts. I have some 500 SNPs and phenotype data for 1200 animals. Out of these 500 I want to select 50-100 SNPs for the selection index. Also i've got some values from the breeding company.Could you please let me know the series of steps that i can follow to achieve my goal(something like a flowchart)?xyzhttps://www.blogger.com/profile/05235461249892255442noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-2052976599531447822015-07-02T07:10:08.407+02:002015-07-02T07:10:08.407+02:00argsL not args for the if statementsargsL not args for the if statementsAnonymoushttps://www.blogger.com/profile/06460367760952611204noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-62971794510582191972015-06-17T05:22:44.323+02:002015-06-17T05:22:44.323+02:00Dear Gregor,
Thank you for bringing this issue up...Dear Gregor,<br /><br />Thank you for bringing this issue up. I too have noticed the lack of a structured website or forum were one can ask questions and participate in discussions related to animal breeding or quantitative genetics theory, tools and other general questions. Since 2011 I have been trying to ask "big names" in the fields to create such an environment but with no luck. An example of such a thing in bioinformatics is Biostar which I personally learned a lot from. I don't know if you have found such an website yet?Mohammedhttps://www.blogger.com/profile/00136347462452660999noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-53570798043734891592015-02-14T23:18:57.795+01:002015-02-14T23:18:57.795+01:00I tried to use Excel2Latex but it does not work wi...I tried to use Excel2Latex but it does not work with Excel 2011 on Mac. :( The link for CSV2latex does not lead anywhere either. I was so frustrated because I really do not want to type my long table in Latex....<br /><br />After some search I fount this site. http://ericwood.org/excel2latex/<br /><br />Hope it can help others as well. :)Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-58339726444051885282014-04-01T18:08:59.449+02:002014-04-01T18:08:59.449+02:00NB. in addition to above, a MUCH faster equivalent...NB. in addition to above, a <i>MUCH</i> faster equivalent method if you have a large dataset is:<br /><br />data.table::fread(paste(dat$z, collapse='\n'), sep='-')<br /><br />Happy parsingAnonymoushttps://www.blogger.com/profile/03037509691503111952noreply@blogger.comtag:blogger.com,1999:blog-6715598735361401237.post-58716982366879705512014-04-01T17:36:33.600+02:002014-04-01T17:36:33.600+02:00The text= argument in read.table is quite useful ...The <i>text=</i> argument in read.table is quite useful in this case - it makes the function treat vectors as if they're lines of a file being read in.<br /><br />read.table(text=dat$z, sep='-')<br /><br />Do I win?Anonymoushttps://www.blogger.com/profile/03037509691503111952noreply@blogger.com