标签

每一个ideogram都会有一个标签:

字体

字体是定义在&ltfont&gt板块的,一般包含在文件colors_fonts_patterns.conf中。 具体设置有:

light          = fonts/modern/cmunbmr.otf
normal         = fonts/modern/cmunbmr.otf
default        = fonts/modern/cmunbmr.otf
semibold       = fonts/modern/cmunbsr.otf
bold           = fonts/modern/cmunbbx.otf
italic         = fonts/modern/cmunbmo.otf
bolditalic     = fonts/modern/cmunbxo.otf
italicbold     = fonts/modern/cmunbxo.otf

使用的时候直接注明 light、normal 就可以了比如: label_font=bold

标签设置:

<ideogram>
show_label     = yes
label_with_tag = yes
label_font     = light
label_radius   = dims(ideogram,radius_outer) + 0.05r
label_center   = yes
label_size     = 48p
label_color    = grey
label_parallel = yes
label_case     = upper 
label_format   = eval(sprintf("chr%s",var(label)))
...
</ideogram>

标签位置:

# 50 pixels outside the outer ideogram radius
label_radius = dims(ideogram,radius_outer) + 50p

# 5% of inner radius outside outer ideogram radius
label_radius = dims(ideogram,radius_outer) + 0.05r

# inside ideogram
label_radius = (dims(ideogram,radius_outer)+dims(ideogram,radius_inner))/2

# 100 pixels inside the ideogram radius
label_radius = dims(ideogram,radius_inner) - 100p

# 50 pixels inside the image radius
label_radius = dims(image,radius) - 50p

label的格式

你可以用一些巧妙的方式来定义lebel的内容:

# show labels only for chromosomes 1-5
label_format     = eval( var(chr) =~ /hs[1-5]$/ ? var(label) : "")

# hide label for chromosome hs10
label_format     = eval( var(chr) eq "hs10" ? "" : var(label))

# replace the string ctg. in the label with empty string (i.e. remove the string)
label_format     = eval( replace(var(label),"ctg.","") )

# use the chromosome name as the label, but replace "hs" with "human "
label_format     = eval( replace(var(chr),"hs","human ") )

# include length in the label (divided by 1,000,000 and suffixed with "Mb")
label_format     = eval( sprintf("%s %dMb",var(label),var(size)/1e6) )

通过帮助获得完整参数列表:

可以使用var()函数的参数名称的完整列表,请使用var(?)。 当Circos解析它时,它将返回(并退出)具有值的参数列表。

# e.g. using
label_format     = eval( sprintf("%s %dMb",var(label),var(?)/1e6) )

# will return
You asked for help in the expression [eval( sprintf("%s %dMb",1,var(?)/1e6) )].
In this expression the arguments marked with * are available for the var() function.
               break   HASH
                 chr * hs1
        chr_with_tag * 1
           chrlength * 249250622
              covers   ARRAY
         display_idx * 0
                 end * 249250621
                 idx * 0
               label * 1
              length   HASH
                next   HASH
               param   HASH
                prev   HASH
              radius * 1350
        radius_inner * 1275
       radius_middle * 1312.5
        radius_outer * 1350
             reverse * 0
               scale * 1
                 set   Set::IntSpan
                size * 249250622
               start * 0
                 tag * hs1
           thickness * 75

results matching ""

    No results matching ""