YinLiLin / CMplot

📊 Circular and Rectangular Manhattan Plot
499 stars 111 forks source link

Error: related cex #111

Open seisland1 opened 8 months ago

seisland1 commented 8 months ago

Hi, I appreciate your code.

I encountered error ""Error in abs(mapply(strwidth, legend, cex = cex, font = text.font, MoreArgs = list(units = "user"))) : non-numeric argument to mathematical function In addition: Warning message: In rep(cex, length.out = n.leg) : 'x' is NULL so the result will be NULL"" like this.

My command was ""CMplot(entire_assoc,type="p",plot.type="c",r=0.4,col=c("grey30","grey60"),chr.labels=paste("Chr",c(1:22),sep=""),threshold=c(1e-6,1e-4),cir.chr.h=1.5,amplify=TRUE,threshold.lty=c(1,2),threshold.col=c("red","blue"),signal.line=1,signal.col=c("red","green"),chr.den.col=c("darkgreen","yellow","red"),bin.size=1e6,outward=FALSE,file="jpg",file.name="Entire_cir",dpi=300,file.output=TRUE,verbose=TRUE,width=10,height=10)"".

FYI, my entire_assoc file is consisted with only SNP, CHR, POS, and P-value.

I look forward to your answer.

Sincerely, Sei Kim.

YinLiLin commented 8 months ago

Hi @seisland1,

I fixed a bug regarding the 'cex' issue proposed by another user just now, please source the online script and have a try to see if it can also address your problem.

Best, LL