<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Guangchuang Yu</title>
    <link>https://guangchuangyu.github.io/</link>
    <description>Recent content on Guangchuang Yu</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en-us</language>
    <lastBuildDate>Thu, 12 Mar 2020 11:08:00 +0800</lastBuildDate><atom:link href="https://guangchuangyu.github.io/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>欧洲很方，一不小心得要「意大利」了</title>
      <link>https://guangchuangyu.github.io/2020/03/ncov2019-global-trend/</link>
      <pubDate>Thu, 12 Mar 2020 11:08:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2020/03/ncov2019-global-trend/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://gitee.com/GuangchuangYu/blog_images/raw/master/nCov2019/2020-03-12_21-40.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;今天我们来重复一下这张图，首先用我们的&lt;a href=&#34;https://mp.weixin.qq.com/s/_0D8ENb-4lGm4UV16Ok28A&#34;&gt;nCov2019包&lt;/a&gt;,我们可以容易地访问到历史记录，&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247488896&amp;amp;idx=1&amp;amp;sn=25e9a7ab2fd81b97052c5941cd0c0c4b&amp;amp;chksm=ec43a4c7db342dd1b417f5c75204ad104dcae252982e9685f8b2d7fab7bccb70d5f83fbeaf69&amp;amp;token=948980768&amp;amp;lang=zh_CN#rd&#34;&gt;nCov2019包中的全球历史数据&lt;/a&gt;， 然后稍微操作一下，就可以拿到所有确诊数超过100的国家，把这个时间当做0点，然后我们就可以对比一下发展趋势了。&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;require&lt;/span&gt;(nCov2019)
&lt;span style=&#34;color:#a6e22e&#34;&gt;require&lt;/span&gt;(dplyr)

d &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;load_nCov2019&lt;/span&gt;()
dd &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; d[&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;global&amp;#39;&lt;/span&gt;] &lt;span style=&#34;color:#f92672&#34;&gt;%&amp;gt;%&lt;/span&gt; 
  as_tibble &lt;span style=&#34;color:#f92672&#34;&gt;%&amp;gt;%&lt;/span&gt;
  &lt;span style=&#34;color:#a6e22e&#34;&gt;rename&lt;/span&gt;(confirm&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;cum_confirm) &lt;span style=&#34;color:#f92672&#34;&gt;%&amp;gt;%&lt;/span&gt;
  &lt;span style=&#34;color:#a6e22e&#34;&gt;filter&lt;/span&gt;(confirm &lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;100&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;%&amp;gt;%&lt;/span&gt;
  &lt;span style=&#34;color:#a6e22e&#34;&gt;group_by&lt;/span&gt;(country) &lt;span style=&#34;color:#f92672&#34;&gt;%&amp;gt;%&lt;/span&gt;
  &lt;span style=&#34;color:#a6e22e&#34;&gt;mutate&lt;/span&gt;(days_since_100 &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;as.numeric&lt;/span&gt;(time &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;min&lt;/span&gt;(time))) &lt;span style=&#34;color:#f92672&#34;&gt;%&amp;gt;%&lt;/span&gt;
  ungroup 
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>新冠全球历史数据爆款风玫瑰图：新冠肺炎全球疫情形势</title>
      <link>https://guangchuangyu.github.io/2020/03/ncov2019-wind-rose/</link>
      <pubDate>Tue, 10 Mar 2020 11:08:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2020/03/ncov2019-wind-rose/</guid>
      <description>&lt;p&gt;最近人民日报新媒体发布的「新冠肺炎全球疫情形势」图，很多人想重复，但画不出来。这其实是几行代码的事情而已。&lt;/p&gt;
&lt;p&gt;这个图，大名叫风玫瑰图，用R画起来分分钟的事情。但你画出来的，可能很丑，要画出爆款，还是有点门槛的。&lt;/p&gt;
&lt;p&gt;这个图确诊数是取过对数，这一点容易，而颜色的映射，也是取对数的，不然的话，前三是红的，其它全绿了。然后标国家和确诊数目，字体还要旋转相应的角度，这一点可能是最难的。当然细节上还有一点，就是中间还要空一个白洞​。​如果你知道怎么加白洞，那么加两圈淡淡的圈也容易了。​&lt;/p&gt;
&lt;p&gt;首先我们用&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247488896&amp;amp;idx=1&amp;amp;sn=25e9a7ab2fd81b97052c5941cd0c0c4b&amp;amp;chksm=ec43a4c7db342dd1b417f5c75204ad104dcae252982e9685f8b2d7fab7bccb70d5f83fbeaf69&amp;amp;token=948980768&amp;amp;lang=zh_CN#rd&#34;&gt;nCov2019包中的全球历史数据&lt;/a&gt;，两三行代码就能拿到。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>新冠全球历史数据</title>
      <link>https://guangchuangyu.github.io/2020/03/ncov-global-data/</link>
      <pubDate>Mon, 09 Mar 2020 11:08:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2020/03/ncov-global-data/</guid>
      <description>&lt;p&gt;我们的&lt;code&gt;nCov2019&lt;/code&gt;包，悄咪咪地加入了全球的历史数据。&lt;/p&gt;
&lt;p&gt;历史数据，一如既往地用&lt;code&gt;load_nCov2019()&lt;/code&gt;函数获得。然后历史数据嘛，也是一样使用&lt;code&gt;x[&#39;global&#39;]&lt;/code&gt;获得。&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;&amp;gt; require(nCov2019)
Loading required package: nCov2019
&amp;gt; x = load_nCov2019()
&amp;gt; d = x[&#39;global&#39;]
&amp;gt; head(d)
        time country cum_confirm cum_heal cum_dead
1 2019-12-01   China           1        0        0
2 2019-12-02   China           1        0        0
3 2019-12-03   China           1        0        0
4 2019-12-04   China           1        0        0
5 2019-12-05   China           1        0        0
6 2019-12-06   China           1        0        0
&amp;gt; tail(d)
           time                        country cum_confirm cum_heal cum_dead
1606 2020-03-08                        Tunisia           1        0        0
1607 2020-03-08                        Ukraine           1        0        0
1608 2020-03-08                  United States         445       10       19
1609 2020-03-08 Holy See  [Vatican City State]           1        0        0
1610 2020-03-08                        Vietnam          30       16        0
1611 2020-03-08                   South Africa           2        0        0
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;之前的&lt;code&gt;lang&lt;/code&gt;参数照常使用，用于指定语言。如果不指定，则会通过R的语言设定来自动设置语言，简单点讲就是你的R是中文的，自动使用中文，其它情况则使用英文。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>biobabble：一个可以查影响因子和分区的公众号</title>
      <link>https://guangchuangyu.github.io/2020/03/check-impact-factor-in-biobabble/</link>
      <pubDate>Sat, 07 Mar 2020 11:08:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2020/03/check-impact-factor-in-biobabble/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://gitee.com/GuangchuangYu/blog_images/raw/master/biobabble/sci-1.jpeg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;正如图中所展示的，你在公众号的后台，发送期刊的全称或简称，它就会返回来这个期刊的信息，当然包括我们最想要知道的影响因子和分区信息。&lt;/p&gt;
&lt;p&gt;这里的简称是官方简称，像图中Methods Ecol Evol，就是Methods in Ecology and Evolution的简称，这是官方的简称，非官方的，比如我们可以说这个杂志是MEE，这种基本上是不被支持的，因为期刊太多，容易撞名。&lt;/p&gt;
&lt;p&gt;所以用起来很简单，全称或简称，输进去，立马出来相关的信息，比如&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>nCov2019英文版，歪果仁也能用这次武汉疫情的数据了</title>
      <link>https://guangchuangyu.github.io/2020/02/english-version-ncov2019/</link>
      <pubDate>Wed, 26 Feb 2020 11:08:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2020/02/english-version-ncov2019/</guid>
      <description>&lt;p&gt;首先你只要用&lt;code&gt;lang=&#39;en&#39;&lt;/code&gt;就行。&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;require(nCov2019)
x = get_nCov2019(lang=&#39;en&#39;)
x[]
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;用法完全一样，输出为：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>nCov2019：历史数据实现自动更新</title>
      <link>https://guangchuangyu.github.io/2020/02/ncov2019-auto-update/</link>
      <pubDate>Mon, 24 Feb 2020 11:08:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2020/02/ncov2019-auto-update/</guid>
      <description>&lt;h2 id=&#34;安装新方式&#34;&gt;安装新方式&lt;/h2&gt;
&lt;p&gt;在《&lt;a href=&#34;https://mp.weixin.qq.com/s/_0D8ENb-4lGm4UV16Ok28A&#34;&gt;检索疫情数据的R包来了&lt;/a&gt;》一文写的安装方式，依然是可行的。但鉴于许多国内的用户，可能在访问github上存在一些问题，我把nCov2019在国内的码云上做了个同步的镜像，所以呢，你也可以通过码云去安装了，安装代码如下：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;## 方法一，使用github
remotes::install_github(&amp;quot;GuangchuangYu/nCov2019&amp;quot;)

## 方法二，使用gitee
remotes::install_git(&#39;https://gitee.com/GuangchuangYu/nCov2019&#39;)
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>Arch滚起来一时爽，滚坏了泪两行</title>
      <link>https://guangchuangyu.github.io/2020/02/arch-grub/</link>
      <pubDate>Thu, 20 Feb 2020 10:44:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2020/02/arch-grub/</guid>
      <description>&lt;p&gt;Arch滚起来一时爽，一直滚啊一直爽，上一次滚出问题还是在笔记本上，《&lt;a href=&#34;https://mp.weixin.qq.com/s/p5b9Xex3PLwu2CKpBCTVCw&#34;&gt;记一次搞死linux又医活的经历&lt;/a&gt;》。&lt;/p&gt;
&lt;p&gt;在台式机上还是第一次，要说只能怪昨天的运气太差。不好好在家待着隔离，跑来办公室，想着爬个楼梯吧，零接触还健康，衣服就被门勾到，拉扯了一下，破了。然后发现自己出门的时候，钥匙没带，只能在实验室过夜了。想想那就当通宵加班吧，干点活，结果把电脑给搞坏了，于是通宵在修电脑，天亮还没好。人在囧途之办公室版本，电视都不敢这么演。&lt;/p&gt;
&lt;p&gt;首先是某灯老连不上，于是&lt;a href=&#34;https://mp.weixin.qq.com/s/8SZo-00_vbWZI3nnbClF_A&#34;&gt;yay&lt;/a&gt;搜一下，发现有新版本，赶紧装。装完却用不了，报错：&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;error while loading shared libraries: libwebkit2gtk-4.0.so.37: cannot open shared object file: No such file or directory&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;搞来搞起，始终运行不了。于是滚动升级整个系统。升完还一样用不了。那么就时光机，回退到老版本吧。因为我基本上隔一段时间，在滚系统之前，都会把整个系统打包。把之前的解压覆盖一下就完整了。十几年前，还在读硕士的时候，就干完笔记本换硬盘，NetBSD系统整个完整搬过去。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>活人不能让尿憋死，自动出来的图例不好调？自己徒手画一个！</title>
      <link>https://guangchuangyu.github.io/2020/02/plot-legend-manual/</link>
      <pubDate>Tue, 18 Feb 2020 11:08:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2020/02/plot-legend-manual/</guid>
      <description>答案嘛，就是自己画legend啊，你看看legend函数，还不是些简单的代码在画，自己画即可。不要被这些条条框框给套住。
从ggplot2拿legend 为了突破你的想像力，在此处甚至于我要给你个例子，用ggplot2来生成个legend，放在base plot上去。
自己画legend，有何不可？！如果base有现成的函数画图，而你只熟悉ggplot2，你甚至于可以互搞。而互搞，当然要借助于ggplotify包：《ggplotify简史》。
col = colorspace::rainbow_hcl(3) names(col) = unique(iris$Species) library(ggplotify) color = col[iris$Species] p = as.ggplot(~plot(iris$Sepal.Length, iris$Sepal.Width, col=color, pch=15)) library(ggplot2) p2 = ggplot(iris, aes(Sepal.Length, Sepal.Width, color=Species)) + geom_point() + scale_color_manual(values=col, name=&amp;quot;&amp;quot;) legend = cowplot::get_legend(p2) p + ggimage::geom_subview(x=.7, y=.6, subview=legend) 这里用base plot画了一个图，又用ggplot2画了一个，用cowplot把legend抽出来，然后再用我的另一个包ggimage进行图上嵌图，完事。ggimage实例可以参考这篇《shit，拟合的残差这么大！》。
用ggplot2画legend 上面这例子是不是还不过瘾，因为啊我还是用ggplot2给重新画了一遍，如果你这么看，那么你的脑洞不够大，画是画了，但不一定要画一样的图，比如说有现成的base函数画复杂的图，而你不会用ggplot2画，但不妨碍你画个简单的图，但这简单的图中的图例可以切出来使用啊。
呼应我上面讲到的，图例自己徒手画，我们用ggplot2来来徒手一下。画出下面这个图例：
p2 &amp;lt;- ggplot() + annotate(&amp;quot;point&amp;quot;, x=1,y=1:3,shape=15, color=col) + annotate(&amp;quot;text&amp;quot;, x=1.01, y=1:3, label=names(col), hjust=0) + xlim(0.99, 1.2) + ylim(0, 4) + theme_void() 对着代码看，不应该有什么问题，打了三个点，再打了三个相应的文本。然后再让我们把这图当做图例，嵌套到base plot上去。
p + ggimage::geom_subview(x=.</description>
    </item>
    
    <item>
      <title>biobabble公众号2019每月精选</title>
      <link>https://guangchuangyu.github.io/2019/12/biobabble-2019/</link>
      <pubDate>Tue, 24 Dec 2019 12:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/12/biobabble-2019/</guid>
      <description>&lt;h2 id=&#34;1月&#34;&gt;1月&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s/IpO3tE7MD0VS1tOdKor1fw&#34;&gt;请问，你需要我帮你google吗？&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;很多人在网络上寻找帮忙而得不到帮助，通常是自己的问题，不要做伸手党，没人欠你一个答案。&lt;/p&gt;
&lt;h2 id=&#34;2月&#34;&gt;2月&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s/ypxeZX_gQW98caoxV_DpOw&#34;&gt;听说你想把pheatmap和ggplot2拼在一起&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;我给&lt;code&gt;pheatmap&lt;/code&gt;加了个输出为&lt;code&gt;pheatmap&lt;/code&gt;对象的功能，再给&lt;code&gt;ggplotify&lt;/code&gt;写个方法，让&lt;code&gt;pheatmap&lt;/code&gt;的输出转为&lt;code&gt;ggplot&lt;/code&gt;，这样就可以不需要grid的知识也可以愉快地进行拼图了。&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;PS: 之前的版本，也是可以拼的，但你需要一点grid的知识。&lt;/p&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>我为什么是个ggpubr黑？</title>
      <link>https://guangchuangyu.github.io/2019/12/why-hate-ggpubr/</link>
      <pubDate>Sat, 21 Dec 2019 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/12/why-hate-ggpubr/</guid>
      <description>&lt;p&gt;很多人用&lt;code&gt;ggpubr&lt;/code&gt;，其实应了那一句「越低俗越舒服」的话，无非是因为用起来简单，当然还有另一个因素，是很多公众号搬运了&lt;code&gt;ggpubr&lt;/code&gt;的文档，而这些写公众号的，多半也是半吊子水平而已，根本没有分辨的能力。&lt;/p&gt;
&lt;p&gt;之前有水生所的小伙伴，在朋友圈发了自己的代码调不好的状态，我评论了一下。&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://gitee.com/GuangchuangYu/blog_images/raw/master/ggpubr/1130620159.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;引出了一个&lt;code&gt;text_grob&lt;/code&gt;的问题，这就是我说的制造混乱，把&lt;code&gt;gpar&lt;/code&gt;几个参数放到&lt;code&gt;gpar&lt;/code&gt;外面提供给用户。&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://gitee.com/GuangchuangYu/blog_images/raw/master/ggpubr/2019-11-21_13-59.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;我不知道你们看出问题在那里没有，这个&lt;code&gt;text_grob&lt;/code&gt;相对于被封装的&lt;code&gt;textGrob&lt;/code&gt;没有提供任何额外的功能，而这个封装就等于把&lt;code&gt;gpar&lt;/code&gt;的参数给写死了，你想调别的参数，没门，除非你用回&lt;code&gt;textGrob&lt;/code&gt;。真是一手好包装。&lt;/p&gt;
&lt;h2 id=&#34;有人说它有好配色&#34;&gt;有人说它有好配色&lt;/h2&gt;
&lt;p&gt;&lt;img src=&#34;https://gitee.com/GuangchuangYu/blog_images/raw/master/ggpubr/2019-11-21_14-09.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;显然是包装的，特别是说什么杂志的配色。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>cowplot是旧爱，patchwork乃新欢</title>
      <link>https://guangchuangyu.github.io/2019/11/patchwork/</link>
      <pubDate>Fri, 22 Nov 2019 15:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/11/patchwork/</guid>
      <description>&lt;p&gt;Thomas Lin Pedersen简直是个天才，最近&lt;code&gt;patchwork&lt;/code&gt;动作很大，看到我都准备转投它的怀抱，把旧爱&lt;code&gt;cowplot&lt;/code&gt;给扔了。&lt;/p&gt;
&lt;p&gt;我们知道&lt;code&gt;patchwork&lt;/code&gt;一出来，就推出&lt;code&gt;+&lt;/code&gt;号来拼图，最近又搞出了&lt;code&gt;|&lt;/code&gt;和&lt;code&gt;/&lt;/code&gt;两个操作符。让整个拼图看起来很舒服。&lt;/p&gt;
&lt;p&gt;先来画几张图：&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;library&lt;/span&gt;(ggplot2)
p1 &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;ggplot&lt;/span&gt;(mtcars) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
  &lt;span style=&#34;color:#a6e22e&#34;&gt;geom_point&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;aes&lt;/span&gt;(mpg, disp)) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
  &lt;span style=&#34;color:#a6e22e&#34;&gt;ggtitle&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;图一&amp;#39;&lt;/span&gt;)

p2 &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;ggplot&lt;/span&gt;(mtcars) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
  &lt;span style=&#34;color:#a6e22e&#34;&gt;geom_boxplot&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;aes&lt;/span&gt;(gear, disp, group &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; gear)) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
  &lt;span style=&#34;color:#a6e22e&#34;&gt;ggtitle&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;图二&amp;#39;&lt;/span&gt;)

p3 &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;ggplot&lt;/span&gt;(mtcars) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
  &lt;span style=&#34;color:#a6e22e&#34;&gt;geom_point&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;aes&lt;/span&gt;(hp, wt, colour &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; mpg)) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
  &lt;span style=&#34;color:#a6e22e&#34;&gt;ggtitle&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;图三&amp;#39;&lt;/span&gt;)

p4 &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;ggplot&lt;/span&gt;(mtcars) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
  &lt;span style=&#34;color:#a6e22e&#34;&gt;geom_bar&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;aes&lt;/span&gt;(gear)) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
  &lt;span style=&#34;color:#a6e22e&#34;&gt;facet_wrap&lt;/span&gt;(&lt;span style=&#34;color:#f92672&#34;&gt;~&lt;/span&gt;cyl) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
  &lt;span style=&#34;color:#a6e22e&#34;&gt;ggtitle&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;图四&amp;#39;&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>进化树和基因组结构</title>
      <link>https://guangchuangyu.github.io/2019/11/geom-motif/</link>
      <pubDate>Thu, 21 Nov 2019 10:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/11/geom-motif/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.gitee.io/blog_images/ggtree/motif-1.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;像上图这种高级货是可以使用ggtree来画的。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>拼图？我掐指一算，发现事情没那么简单！</title>
      <link>https://guangchuangyu.github.io/2019/11/xlim2-ylim2/</link>
      <pubDate>Mon, 18 Nov 2019 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/11/xlim2-ylim2/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.gitee.io/blog_images/ggtree/axis-align/1.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;拼图很容易，像上面这张图，就是三张图拼在一起，但你仔细看一下，这结果可能不是你想要的，如果我们想要坐标轴按照值的大小对齐呢？&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ChIPseeker其实支持顺反组的各种测序数据</title>
      <link>https://guangchuangyu.github.io/2019/11/chipseeker-atac-dnase-seq/</link>
      <pubDate>Fri, 15 Nov 2019 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/11/chipseeker-atac-dnase-seq/</guid>
      <description>&lt;p&gt;ChIPseeker是为ChIP-seq所设计的，因为当年我在做ChIP-seq，一不小心就写了这个包，然而我的知识是有限的，这名字取得太过于限定在ChIP-seq了，其实顺反组的其它类型的测序技术都是支持的，包括DNase-seq和ATAC-seq，此处为了说明我当前的知识是有限的，必须强调不仅限于此，免得出现开头说的这种尴尬。&lt;/p&gt;
&lt;p&gt;8月份去开会，有中大肿瘤医院的PI跟我说，他们希望ChIPseeker可以支持ATAC-seq，因为我的ChIPseeker太好用了，然后他们想要用在ATAC-seq上，然而我的包真的是支持的啊。&lt;/p&gt;
&lt;p&gt;哈佛大学的网站上有一份ATAC-seq分析指南[1]，就明确地写了，ChIPseeker虽然是为ChIP-seq所设计，但对ATAC-seq一样支持得非常好，并且把ChIPseeker列为这份指南的关键步骤之一。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>clusterProfiler.dplyr：用dplyr操作富集分析结果</title>
      <link>https://guangchuangyu.github.io/2019/11/clusterprofiler-dplyr/</link>
      <pubDate>Fri, 01 Nov 2019 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/11/clusterprofiler-dplyr/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.gitee.io/blog_images/clusterProfiler/qestion.jpeg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;出错的原因在于，我根本就没给GSEA分析的结果写barplot方法，所以默认去调用graphics::barplot.default了，于是出错。&lt;/p&gt;
&lt;p&gt;但这样的图，对于我们来说，简直简单的不要不要的。&lt;/p&gt;
&lt;p&gt;首先跑一下GSEA的分析, 这里用ReactomePA来跑一下通路的GSEA分析：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggplot2小技巧-数据没有，函数倒是有一个</title>
      <link>https://guangchuangyu.github.io/2019/10/funtion-for-data/</link>
      <pubDate>Sun, 27 Oct 2019 18:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/10/funtion-for-data/</guid>
      <description>&lt;p&gt;今天讲一个小技巧，首先数据还是得有，很简单地生成一些随机数：&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;set.seed&lt;/span&gt;(&lt;span style=&#34;color:#ae81ff&#34;&gt;2019-10-23&lt;/span&gt;)
d &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;data.frame&lt;/span&gt;(val&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;abs&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;rnorm&lt;/span&gt;(&lt;span style=&#34;color:#ae81ff&#34;&gt;20&lt;/span&gt;)), 
                type&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;rep&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;c&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;A&amp;#39;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;B&amp;#39;&lt;/span&gt;), &lt;span style=&#34;color:#ae81ff&#34;&gt;10&lt;/span&gt;))
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;20个数长这样子：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;          val type
1  0.04625141    A
2  0.28000082    B
3  0.25317063    A
4  0.96411077    B
5  0.49222664    A
6  0.69874551    B
7  0.82134409    A
8  0.70966741    B
9  1.56752284    A
10 1.12881681    B
11 0.82488089    A
12 0.19897743    B
13 0.76739568    A
14 0.70597703    B
15 0.24332380    A
16 0.55423292    B
17 2.49008811    A
18 1.35153628    B
19 2.13711738    A
20 0.92299795    B
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>一条相见恨晚的指令</title>
      <link>https://guangchuangyu.github.io/2019/10/open-all-files/</link>
      <pubDate>Wed, 09 Oct 2019 18:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/10/open-all-files/</guid>
      <description>&lt;h2 id=&#34;macos&#34;&gt;MacOS&lt;/h2&gt;
&lt;p&gt;MacOS用户如果有用命令行的话，大多数人应该知道open .会打开Finder。事实上它能打开所有的目录，比如:&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;$ open ~/Library/Preferences
$ open /etc
$ open ../..
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;你还能同时打开多个目录：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;$ open ~/Documents ~/Desktop ~/Downloads
$ open ~/D*
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;然后它还能打开各种文件，比如：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;$ open document.pdf
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>一样的函数，不一样的upset</title>
      <link>https://guangchuangyu.github.io/2019/09/a-different-upset-plot/</link>
      <pubDate>Fri, 27 Sep 2019 18:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/09/a-different-upset-plot/</guid>
      <description>&lt;p&gt;upsetplot大家见得多，首先来个富集分析的实例：&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;library&lt;/span&gt;(DOSE)
&lt;span style=&#34;color:#a6e22e&#34;&gt;data&lt;/span&gt;(geneList)
de &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;names&lt;/span&gt;(geneList)&lt;span style=&#34;color:#a6e22e&#34;&gt;[abs&lt;/span&gt;(geneList) &lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;]
edo &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;enrichDGN&lt;/span&gt;(de)

&lt;span style=&#34;color:#a6e22e&#34;&gt;library&lt;/span&gt;(enrichplot)
&lt;span style=&#34;color:#a6e22e&#34;&gt;upsetplot&lt;/span&gt;(edo)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>shit，拟合的残差这么大！</title>
      <link>https://guangchuangyu.github.io/2019/09/shit-residual/</link>
      <pubDate>Thu, 26 Sep 2019 18:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/09/shit-residual/</guid>
      <description>&lt;p&gt;《&lt;a href=&#34;http://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247486708&amp;amp;idx=1&amp;amp;sn=8da7f94fe242a094b0eef88e359c1afe&amp;amp;chksm=ec43bdb3db3434a5aefd2032229ef0efb8dd0380719aa4f0a4e6773bf6e9216733e8e8a90f29&amp;amp;scene=21#wechat_redirect&#34;&gt;基佬的屁股和科学家的屎，之间的共同点是&amp;hellip;!&lt;/a&gt;》这篇推文发表之后，发现大家对屎尿屁还是蛮有兴趣的，画屎除了展示的emojifont包之外，也提到了ggimage包，其实用ggimage包更有趣！这里也演示一下，一起来玩屎，看看自己到底是搅屎棍还是化粪池！玩屎玩出花来。&lt;/p&gt;
&lt;p&gt;先来一张线性拟合的图：&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;set.seed&lt;/span&gt;(&lt;span style=&#34;color:#ae81ff&#34;&gt;123&lt;/span&gt;)
iris2 &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; iris&lt;span style=&#34;color:#a6e22e&#34;&gt;[sample&lt;/span&gt;(&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;nrow&lt;/span&gt;(iris), &lt;span style=&#34;color:#ae81ff&#34;&gt;30&lt;/span&gt;), ]
model &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;lm&lt;/span&gt;(Petal.Length &lt;span style=&#34;color:#f92672&#34;&gt;~&lt;/span&gt; Sepal.Length, data &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; iris2)
iris2&lt;span style=&#34;color:#f92672&#34;&gt;$&lt;/span&gt;fitted &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;predict&lt;/span&gt;(model)

iris3 &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; iris2&lt;span style=&#34;color:#a6e22e&#34;&gt;[abs&lt;/span&gt;(iris2&lt;span style=&#34;color:#f92672&#34;&gt;$&lt;/span&gt;Petal.Length&lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt;iris2&lt;span style=&#34;color:#f92672&#34;&gt;$&lt;/span&gt;fitted) &lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0.5&lt;/span&gt;,]
p &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;ggplot&lt;/span&gt;(iris2, &lt;span style=&#34;color:#a6e22e&#34;&gt;aes&lt;/span&gt;(x &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; Sepal.Length, y &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; Petal.Length)) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;
    &lt;span style=&#34;color:#a6e22e&#34;&gt;geom_point&lt;/span&gt;() &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;
    &lt;span style=&#34;color:#a6e22e&#34;&gt;geom_linerange&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;aes&lt;/span&gt;(ymin &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; fitted, ymax &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; Petal.Length),
                   data&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;iris3, colour &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;purple&amp;#34;&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;
    &lt;span style=&#34;color:#a6e22e&#34;&gt;geom_abline&lt;/span&gt;(intercept &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; model&lt;span style=&#34;color:#f92672&#34;&gt;$&lt;/span&gt;coefficients[1],
                slope &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; model&lt;span style=&#34;color:#f92672&#34;&gt;$&lt;/span&gt;coefficients[2])
p
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>还想用clusterProfiler以前的那些画图函数，怎么办？</title>
      <link>https://guangchuangyu.github.io/2019/09/doseplot/</link>
      <pubDate>Thu, 19 Sep 2019 18:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/09/doseplot/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.gitee.io/blog_images/doseplot/p1.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.gitee.io/blog_images/doseplot/p2.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;I have been using clusterProfiler, which is a very useful package for gene set analysis and visualisation. I would like to use the &amp;lsquo;cnetplot&amp;rsquo; function to plot a network of GO terms and the related genes. However for larger networks, the automatic display can be confusing and it would be helpful to be able to move nodes around. In the past I could do this with with cnetplot(fixed=FALSE) option, but after updating R and re-installing clusterProfiler, the output remains static.&lt;/p&gt;
&lt;p&gt;I am using R 3.5.3 with clusterProfiler v3.10.1 which I installed using Bioconductor 3.8. I have installed and loaded the &amp;lsquo;igraph&amp;rsquo; package, and the following test code produces output in an interactive window, as desired:&lt;/p&gt;
&lt;p&gt;library(igraph)
g &amp;lt;- make_ring(10)
tkplot(g)&lt;/p&gt;
&lt;p&gt;Is there any way to make cnetplot output interactive, or is that functionality simply not available in the latest release?&lt;/p&gt;
&lt;p&gt;Any help would be greatly appreciated!&lt;/p&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title> 听说你想把Gviz画的基因结构转成ggplot?</title>
      <link>https://guangchuangyu.github.io/2019/09/ggplotify-gviz/</link>
      <pubDate>Tue, 03 Sep 2019 18:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/09/ggplotify-gviz/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.gitee.io/blog_images/ggplotify/gviz-1.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;在《&lt;a href=&#34;http://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247487870&amp;amp;idx=1&amp;amp;sn=836f75a9e6bd17a77a0b886056e51e29&amp;amp;chksm=ec43a039db34292fcd3a618ce4b5f9bebe5bc8414a6d7de196e51bd77177886f9cd81a2472b9&amp;amp;scene=21#wechat_redirect&#34;&gt;ggplotify - version 0.0.4&lt;/a&gt;》一文中，有粉丝说想要支持Gviz包，画图包如果输出的是对象，那么我们可以写方法针对这个对象，然而Gviz的输出，却是list，显然这个方法走不通。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>让我们画个黑板报吧</title>
      <link>https://guangchuangyu.github.io/2019/08/geom-bgimage/</link>
      <pubDate>Wed, 21 Aug 2019 18:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/08/geom-bgimage/</guid>
      <description>&lt;p&gt;上次推送的《geom_bgimage》，竟然有人问说用ggplot2怎么搞。明明我的例子就是了，虽然用的是ggtree的例子，但与ggplot2何异？&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;require&lt;/span&gt;(ggplot2)
&lt;span style=&#34;color:#a6e22e&#34;&gt;require&lt;/span&gt;(ggimage)

d &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;data.frame&lt;/span&gt;(x&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;LETTERS&lt;/span&gt;[1&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;3&lt;/span&gt;], y &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;3&lt;/span&gt;)
d&lt;span style=&#34;color:#f92672&#34;&gt;$&lt;/span&gt;y2 &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;rev&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;cumsum&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;rev&lt;/span&gt;(d&lt;span style=&#34;color:#f92672&#34;&gt;$&lt;/span&gt;y)))

p &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;ggplot&lt;/span&gt;(d, &lt;span style=&#34;color:#a6e22e&#34;&gt;aes&lt;/span&gt;(x&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;, y, fill&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;x)) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;geom_col&lt;/span&gt;(color&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;white&amp;#39;&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;  
 &lt;span style=&#34;color:#a6e22e&#34;&gt;geom_bgimage&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;img/blackboard.jpg&amp;#34;&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;theme_void&lt;/span&gt;() &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;
 &lt;span style=&#34;color:#a6e22e&#34;&gt;coord_polar&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;y&amp;#34;&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;theme&lt;/span&gt;(legend.position&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;none&amp;#39;&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
 &lt;span style=&#34;color:#a6e22e&#34;&gt;geom_text&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;aes&lt;/span&gt;(y &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; y2 &lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt; y&lt;span style=&#34;color:#f92672&#34;&gt;/&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;, label&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;x),family&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;xkcd&amp;#39;&lt;/span&gt;, size&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;8&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
 &lt;span style=&#34;color:#a6e22e&#34;&gt;xlim&lt;/span&gt;(&lt;span style=&#34;color:#ae81ff&#34;&gt;-1&lt;/span&gt;, &lt;span style=&#34;color:#66d9ef&#34;&gt;NA&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;scale_fill_viridis_d&lt;/span&gt;()
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>魔镜魔镜告诉我 - 那里的水管最粗大</title>
      <link>https://guangchuangyu.github.io/2019/06/mirrorselect/</link>
      <pubDate>Thu, 06 Jun 2019 18:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/06/mirrorselect/</guid>
      <description>&lt;p&gt;刚到南医大的时候，装R包感觉速度挺慢，虽然说教育网嘛，反正用教育网的镜像就对了，但我还是产生了要给镜像测测速的想法。于是着手写了mirrorselect这个包。&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.gitee.io/blog_images/screenshot/mirrorselect-1.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>画点之组内再分组</title>
      <link>https://guangchuangyu.github.io/2019/06/position-jitter/</link>
      <pubDate>Wed, 05 Jun 2019 18:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/06/position-jitter/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.gitee.io/blog_images/ggplot2/position-jitter-email.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247485644&amp;amp;idx=1&amp;amp;sn=a273d17668d4847b1df8c12546f78351&amp;amp;scene=21#wechat_redirect&#34;&gt;画图给点分组?&lt;/a&gt;》这一篇文章中给出了方法，画出两层分组的点图，一层分组是按照离散型变量在x轴上分组，第二层是每一个分组里，再来一个离散型变量再分一次。非常感谢读者们的反馈，原来这第二层分组在ggplot2中是有内置的实现方式的，那就是&lt;code&gt;position_jitterdodge&lt;/code&gt;。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>你那一串差异基因，到底是在哪个组织、哪种细胞中富集？</title>
      <link>https://guangchuangyu.github.io/2019/05/clusterprofiler-cellmarker/</link>
      <pubDate>Tue, 28 May 2019 18:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/05/clusterprofiler-cellmarker/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.gitee.io/blog_images/screenshot/cell-marker-1.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;有一个叫CellMarker的数据库，专门收录组织和细胞的基因标记物，收录还比较全，而且是手工校对的（可怜一下干这种脏活的研究生三秒钟）。&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;By manually curating over 100 000 published papers, 4124 entries including the cell marker information, tissue type, cell type, cancer information and source, were recorded. At last, 13 605 cell markers of 467 cell types in 158 human tissues/sub-tissues and 9148 cell makers of 389 cell types in 81 mouse tissues/sub-tissues were collected and deposited in CellMarker.&lt;/p&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>史前人类怎么使用R</title>
      <link>https://guangchuangyu.github.io/2019/05/base-r/</link>
      <pubDate>Wed, 08 May 2019 18:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/05/base-r/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.gitee.io/blog_images/screenshot/apply.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.gitee.io/blog_images/screenshot/uncle_y-apply.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;群里大家给出各种解法，但似乎避开了dplyr之后，大家还是会用到plyr或者purrr，没人给出我讲的apply套split的纯base R的解法。&lt;/p&gt;
&lt;p&gt;套两重for循环，会让人容易理解一点，而且代码也非常简单，但效率不行，用apply的话，处理各种list，特别如果要list套list，很多人就比较懵逼，需要借助于plyr或purrr，甚至还有人的解法虽然不用dplyr的group_by套summarise，但用了dplyr其它的函数。tidyverse真的太好用，对低端R用户照顾得太好，大家都被惯坏了，但想一下，以前的人真的就不用活了吗？&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>那些我讲过的oral</title>
      <link>https://guangchuangyu.github.io/2019/04/oral-presentation/</link>
      <pubDate>Thu, 25 Apr 2019 05:54:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/04/oral-presentation/</guid>
      <description>&lt;h3 id=&#34;2016潮博沙龙&#34;&gt;2016潮博沙龙&lt;/h3&gt;
&lt;p&gt;《&lt;a href=&#34;https://mp.weixin.qq.com/s/K7yojzsGx2-x6bTOz9MHtw&#34;&gt;潮博沙龙&lt;/a&gt;》系受到潮博群里大家的邀请，应邀去普及一下生信以及介绍自己的一些经历。&lt;/p&gt;
&lt;h3 id=&#34;2016中国r语言大会&#34;&gt;2016中国R语言大会&lt;/h3&gt;
&lt;p&gt;中国R语言大会，我到目前为止，只参加过2016年那一次，也就是第9届，那也是首次有Bioconductor分会，并且还邀请了bioconductor的老大martin morgan，我当时也是受邀请去参会的，虽然会议在人民大学举行，虽然主会场和其它分会场都是讲中文，但bioconductor分会场是要求讲英文的。因为主讲人一半是歪果仁，一半是中国人，而3个中国人之中又有两个是美帝来的，只有我一土鳖。本来邀请人跟我提了一下&lt;code&gt;ChIPseeker&lt;/code&gt;，暗示可以讲这个包，但我强行去讲&lt;code&gt;ggtree&lt;/code&gt;，然后会后，很多听众问我&lt;code&gt;clusterProfiler&lt;/code&gt;的问题，也是挺尬聊的。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>我不会用illustrator，只会用ppt！</title>
      <link>https://guangchuangyu.github.io/2019/04/export-office/</link>
      <pubDate>Mon, 01 Apr 2019 12:20:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/04/export-office/</guid>
      <description>&lt;p&gt;当年我准备考博的时候，健康院某PI（本来的意向导师）找我帮他在iMac上安装盗版的&lt;code&gt;Papers&lt;/code&gt;（文献管理器）和&lt;code&gt;Illustrator&lt;/code&gt;（PS的兄弟），安装后，跟我说：“我们做科研的，最重要的软件就是Papers和Illustrator。”，当然后来感觉挺坑我，就放弃了。&lt;/p&gt;
&lt;p&gt;这么多年过去了，至今这两个软件我都没用过！我画图，追求的是全部由代码产生，至今还没有修图的需求，也就没有试过&lt;code&gt;Illustrator&lt;/code&gt;了。&lt;/p&gt;
&lt;p&gt;&lt;code&gt;Illustrator&lt;/code&gt;必须有些门槛，而且关键是&lt;code&gt;Adobe&lt;/code&gt;绑死在PDF上，实际上如果80%的问题都可以用&lt;code&gt;PowerPoint&lt;/code&gt;解决，剩下那20%，反正也不常用。而&lt;code&gt;PowerPoint&lt;/code&gt;的优点是没有门槛，傻瓜式操作，像我这种怀疑自己智商的人，都会用啊！&lt;/p&gt;
&lt;p&gt;要是&lt;code&gt;R&lt;/code&gt;画的图，能够在&lt;code&gt;PowerPoint&lt;/code&gt;里面编辑就好了！&lt;/p&gt;
&lt;p&gt;要是&lt;code&gt;R&lt;/code&gt;画的图，能够在&lt;code&gt;PowerPoint&lt;/code&gt;里面编辑就好了！&lt;/p&gt;
&lt;p&gt;要是&lt;code&gt;R&lt;/code&gt;画的图，能够在&lt;code&gt;PowerPoint&lt;/code&gt;里面编辑就好了！&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>biobabble的作者们</title>
      <link>https://guangchuangyu.github.io/2019/03/biobabble-author/</link>
      <pubDate>Thu, 28 Mar 2019 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/03/biobabble-author/</guid>
      <description>&lt;p&gt;在《&lt;a href=&#34;https://mp.weixin.qq.com/s/kmezZTCSa_F_Lx7f4a8ZTA&#34;&gt;R-3.6 &amp;ndash; set.seed&lt;/a&gt;》和《&lt;a href=&#34;https://mp.weixin.qq.com/s/NZSfAVlWuJkuFsNDo_NMiw&#34;&gt;欧式距离如何应对缺失值？&lt;/a&gt;》中暴露了&lt;code&gt;biobabble&lt;/code&gt;作者群，今天就来揭秘一下。&lt;/p&gt;
&lt;p&gt;凡是给本公众号投过稿，或者是被我约过稿的，都会被我拉入群，目前在群里有8个小伙伴，分别是有原创文章发表在&lt;code&gt;biobabble&lt;/code&gt;公众号的，其中有介绍自己的软件工具的，包括&lt;code&gt;scihub_ck&lt;/code&gt;，&lt;code&gt;csvtk&lt;/code&gt;，&lt;code&gt;bioView&lt;/code&gt;, &lt;code&gt;basicTrendline&lt;/code&gt;等优秀作品，首次在公众号平台上介绍。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>欧式距离如何应对缺失值</title>
      <link>https://guangchuangyu.github.io/2019/03/euclidean-distance-with-na-values/</link>
      <pubDate>Thu, 14 Mar 2019 12:37:55 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/03/euclidean-distance-with-na-values/</guid>
      <description>&lt;p&gt;biobabble作者群有一个小伙伴提出来的问题。&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;没错，凡是给biobabble投稿的小伙伴都会被拉入作者群。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;话说有一个矩阵，我们让它某个值缺失，算出来的距离和原来的竟然是一样的：&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; dat &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;matrix&lt;/span&gt;(&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;10&lt;/span&gt;, &lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;)
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;dist&lt;/span&gt;(dat)
         &lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;
&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;2.236068&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; dat[1,&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;] &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;NA&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;dist&lt;/span&gt;(dat)
         &lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;
&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;2.236068&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;这有点反直觉，实际上你再搞个缺失值，它算出来还是一样的：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;&amp;gt; dat[1,3] = NA
&amp;gt; dist(dat)
         1
2 2.236068
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;但以我的经验，我通常不敢轻易说人家有bug，我们得确认一下。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggupset -- ggplot2版本的upset plot</title>
      <link>https://guangchuangyu.github.io/2019/03/ggupset/</link>
      <pubDate>Mon, 11 Mar 2019 09:33:50 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/03/ggupset/</guid>
      <description>&lt;p&gt;在《&lt;a href=&#34;https://mp.weixin.qq.com/s/PPtYmZdCbAzFdvTI1Tb6gQ&#34;&gt;一图告诉你venn plot和upset plot的关系&lt;/a&gt;》一文中，我们应该很清楚这两者的关系，upset plot是更清晰的呈现方式，而且能够支持无数多个分类，在《&lt;a href=&#34;https://mp.weixin.qq.com/s/g6rRGhtKQd_mdRMKxteNVw&#34;&gt;转UpSet图为ggplot?&lt;/a&gt;》一文中，又介绍了一个转化UpSetR输出为ggplot2便于嵌图和拼图的方法，但这个需要一个补丁，然后我提交的这个补丁，一直没有被作者接收。而且毕竟UpSetR是用grid写的，像grid这种高级货，玩起来还是有点难度，我一直在想应该有一个&lt;code&gt;ggplot2&lt;/code&gt;版本的upset plot，最近就让我在gayhub上发现了。&lt;/p&gt;
&lt;p&gt;这包已经在CRAN上，所以可以用最简单的方式安装：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;install.packages(&amp;quot;ggupset&amp;quot;)
&lt;/code&gt;&lt;/pre&gt;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;library(tidyverse)
library(ggupset)

tidy_movies %&amp;gt;%
  distinct(title, year, length, .keep_all=TRUE) %&amp;gt;%
  ggplot(aes(x=Genres)) +
    geom_bar() +
    scale_x_upset(n_intersections = 20)
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>你还在愁毕业？隔壁实验室的小哥从网上抄了几十行代码打了个R包，发了SCI，毕业了！</title>
      <link>https://guangchuangyu.github.io/2019/03/gogadget/</link>
      <pubDate>Fri, 08 Mar 2019 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/03/gogadget/</guid>
      <description>&lt;p&gt;你是否对《&lt;a href=&#34;https://mp.weixin.qq.com/s/JODhkZ5-qPMDx1zrWHyW_w&#34;&gt;R包辣鸡之CorMut&lt;/a&gt;》之篇还有印象？没有的话，快点打开阅读一下，这文章让作者毕业了，毕竟发表的是一篇Bioinformatics。&lt;/p&gt;
&lt;p&gt;《&lt;a href=&#34;http://mp.weixin.qq.com/s/AsRxsRw-0N5HOSqN0d_IIw&#34;&gt;[连载3]：辣眼睛，一篇抄袭引发的系列血案！&lt;/a&gt;》，而这一篇文章中揭露了某讲师抄袭了两个R包，晋升副教授了！文章中还稍带了另外一个学生也是抄袭，当然也发表了SCI，也毕业了。&lt;/p&gt;
&lt;p&gt;今天讲另外一个R包，它做下面的事情：&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/R/gogadget/workflow.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;当然前面的事情是goseq干的，它的功能就是衔接了goseq的输出，让我们还看看它每一步都在做什么。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>港校申请指北：考研考博失利之后的另一选择</title>
      <link>https://guangchuangyu.github.io/2019/03/hku-application/</link>
      <pubDate>Tue, 05 Mar 2019 00:30:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/03/hku-application/</guid>
      <description>&lt;p&gt;最近有一些考研失利的同学问我怎么申请香港的学校，其实我的经验并不多，因为我读博的时候，&lt;a href=&#34;https://mp.weixin.qq.com/s/LzwSAYT7yyYTMrNnck9KCg&#34;&gt;并没有想要去香港&lt;/a&gt;，在港大临近截止日期的时候，很突然地去申请，然后竟然中了。当然毕竟在港大也待了几年，要说经验，多少也是有一点的。&lt;/p&gt;
&lt;h3 id=&#34;为什么港校是一个选择&#34;&gt;为什么港校是一个选择&lt;/h3&gt;
&lt;p&gt;美帝的话，基本上可以说已经没机会了。要的话，再过一年，请赶早。欧洲还是有些机会的，因为欧洲读博就跟工作似的，有时候有funding了，打了广告，就招人了。只不过你要时刻去留意，而且不一定能让你撞上。&lt;/p&gt;
&lt;p&gt;而港大（其它香港学校我不了解），每年招3轮学生，分别在12月、4月、8月，刚好如果你考研或考博之后，不管考得好不好，都可以试一下，给自己多一个选择，因为4月31号截止，时间不冲突，完全赶得上。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>听说你想把pheatmap和ggplot2拼在一起</title>
      <link>https://guangchuangyu.github.io/2019/03/pheatmap-ggplotify/</link>
      <pubDate>Sun, 03 Mar 2019 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/03/pheatmap-ggplotify/</guid>
      <description>&lt;p&gt;在《&lt;a href=&#34;https://mp.weixin.qq.com/s/NaUQ5KhRRN8cx4v798w9Qg&#34;&gt;一个更好用的pheatmap&lt;/a&gt;》一文中介绍了pheatmap的新功能，它输出为一个pheatmap的对象，这个对象在终端上打出来，会出来图，你可以用ggplot2::ggsave()来保存图片，文章的结尾处卖了一个关子，就是用cowplot来拼，这个有许多人问过我，因为大家一般都认为cowplot只能用于ggplot2的输出，pheatmap感觉好像不太行，而且在很多人的感觉中，画图代码不是ggplot2写的，就是base写的，而pheatmap看上去就像是base一般，其实它是grid写的，我在下面两篇文章中都有示例代码，用于拼pheatmap，不过一般人看过了，也只是留下一点印象，终究还是记不住，因为涉及到grid的知识。&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;http://mp.weixin.qq.com/s/Xhi_ZkrEzUVdnCu7ECBS4w&#34;&gt;听说你还不会画热图&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s/yVLgGQQi0CQ9Q9UfIKl5aA&#34;&gt;不同数据集画出的热图，用同样的颜色区间上色?&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;现在我们有一种你一定能记得住的方法了，以后再也不用问pheatmap怎么拼图了，首先pheatmap产生的是一个对象，然后这个对象我们可以用ggplot2给画出来，然后自然而然你能够用cowplot去拼，再熟悉不过了，如果这都不能理解记住，那我也没办法了。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>图层中的统计量，你自己说的算！</title>
      <link>https://guangchuangyu.github.io/2019/02/layer-stats/</link>
      <pubDate>Thu, 21 Feb 2019 18:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/02/layer-stats/</guid>
      <description>&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;library&lt;/span&gt;(ggplot2)

pups &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; nlme&lt;span style=&#34;color:#f92672&#34;&gt;::&lt;/span&gt;RatPupWeight &lt;span style=&#34;color:#f92672&#34;&gt;%&amp;gt;%&lt;/span&gt; 
    janitor&lt;span style=&#34;color:#f92672&#34;&gt;::&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;clean_names&lt;/span&gt;() &lt;span style=&#34;color:#f92672&#34;&gt;%&amp;gt;%&lt;/span&gt;
    dplyr&lt;span style=&#34;color:#f92672&#34;&gt;::&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;mutate&lt;/span&gt;(litter &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;as.integer&lt;/span&gt;(litter))

p &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;ggplot&lt;/span&gt;(pups, &lt;span style=&#34;color:#a6e22e&#34;&gt;aes&lt;/span&gt;(x &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; litter, y &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; weight, color &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; treatment))
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;针对某一个x值，我们可以画出相应y的统计量，比如均值、方差等，这些都可以“手工”的方式通过图层叠加来实现。&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;p &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;geom_jitter&lt;/span&gt;(shape&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
    &lt;span style=&#34;color:#a6e22e&#34;&gt;stat_summary&lt;/span&gt;(fun.y &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;mean&amp;#34;&lt;/span&gt;, size&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;, geom&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;point&amp;#34;&lt;/span&gt;, color &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;black&amp;#39;&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
    &lt;span style=&#34;color:#a6e22e&#34;&gt;stat_summary&lt;/span&gt;(fun.data &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; mean_cl_normal, geom&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;errorbar&amp;#34;&lt;/span&gt;, width&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;.1&lt;/span&gt;, color&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;black&amp;#39;&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>请问，你是要我帮你google吗？</title>
      <link>https://guangchuangyu.github.io/2019/01/lmgtfy/</link>
      <pubDate>Wed, 16 Jan 2019 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/01/lmgtfy/</guid>
      <description>&lt;h3 id=&#34;怎么提问是需要学习的&#34;&gt;怎么提问，是需要学习的&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;http://mp.weixin.qq.com/s/fvCsdNVl87PtKuGXmcikDw&#34;&gt;how to bug author&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s/8ZwlWmJqGJ3Sl0v-4MduQA&#34;&gt;为什么你的提问被无情地无视了！&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;我写过不少文章，都有提及提问的礼仪，会提问的人，比较容易得到帮助，而不会提问的人，理你才怪，比如说明明出错信息很明显，还给了你解决的提示而你却不看。举个例子现在需要编译的R包，如果缺少库文件，报错的话，一般会提示你Debian/Ubuntu系列apt安装什么包，Redhat系列yum安装什么，MacOS的话，brew安装什么，你按照提示装上再说，你不懂的话，你还不会把出错信息贴出来google一下吗？一般都有人解决了。
一个错误的示范&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>clusterProfiler事后丸: 转换ID为SYMBOL</title>
      <link>https://guangchuangyu.github.io/2019/01/clusterprofiler-setreadable/</link>
      <pubDate>Mon, 14 Jan 2019 15:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/01/clusterprofiler-setreadable/</guid>
      <description>&lt;p&gt;有一些软件做了检验之后，是不告诉你那些基因在某个富集的通路中，显然做为生物学家，是对此有兴趣的。&lt;code&gt;clusterProfiler&lt;/code&gt;系列，全部函数都会输出，但看基因ID，比如ENTREZID或ENSEMBLE，这些都对人类不友好，看了你也不知道是什么，为了让大家看结果的时候，还能有点感觉，我们需要把基因翻译成symbol，有那么一批函数比如DO、GO、Reactome的分析都是有&lt;code&gt;readable&lt;/code&gt;参数的，但有一些是没有这个参数的，我被问得最多的是KEGG的分析为什么没有！&lt;/p&gt;
&lt;p&gt;首先GO为什么有？因为&lt;code&gt;enrichGO&lt;/code&gt;和&lt;code&gt;gseGO&lt;/code&gt;都是使用&lt;code&gt;OrgDb&lt;/code&gt;，而&lt;code&gt;OrgDb&lt;/code&gt;本身带有ID转换的注释，而KEGG是在线去检索KEGG数据库的，KEGG并没有提供这些信息，当然对于少量大家比较熟悉的模式生物，要支持还是很容易的，然而有些物种支持，有些不支持，大家又会问了，凭什么我做的物种被BS了。所以啊，大家都不支持，挺公平。其实KEGG数据库里那么多的生物，很多物种是没有基因名的，有很多生物的注释还停留在基因座，你让我帮你转ID，臣妾做不到啊。&lt;/p&gt;
&lt;p&gt;但起码对能支持的物种支持一下呗，以我一贯的作风，能帮小白解决的小问题，我都会去解决。于是我们有&lt;code&gt;setReadable&lt;/code&gt;函数。但凡你能找到一个OrgDb，你就能用来转ID，就这样。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>听说你R脚本中的数据丢了，图出不来！</title>
      <link>https://guangchuangyu.github.io/2019/01/print-data/</link>
      <pubDate>Fri, 11 Jan 2019 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/01/print-data/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;有小伙伴问为什么R里循环出不来图？&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;其实看我公众号的各位读者们，你们不应该有这个问题，如果有，那么证明我的文章没有好好看！有两篇很重要的文章《&lt;a href=&#34;http://mp.weixin.qq.com/s/BPY4dPFrrNrDKccMvax07w&#34;&gt;扪心自问，meme几何？&lt;/a&gt;》和《&lt;a href=&#34;http://mp.weixin.qq.com/s/Uhx3l3lKQS88OJ4SHntkNg&#34;&gt;树变图，图变树？&lt;/a&gt;
？》，特别是第二篇，和这个问题息息相关。&lt;/p&gt;
&lt;p&gt;首先假设我们有一个图：&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;require&lt;/span&gt;(ggplot2)
p &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;qplot&lt;/span&gt;(&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;10&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h3 id=&#34;为什么在终端打p可以出图&#34;&gt;为什么在终端打p可以出图？&lt;/h3&gt;
&lt;p&gt;因为在R里，所有都是对象，而在终端里你输入一个对象回车，R会去找相应的方法去打印出来，如果是S3对象，会去寻找print方法，而如果是S4会去找show方法。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>自定义注释分类</title>
      <link>https://guangchuangyu.github.io/2019/01/custom-annotation-in-annotatepeak/</link>
      <pubDate>Thu, 10 Jan 2019 12:20:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2019/01/custom-annotation-in-annotatepeak/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Hi Guangchuang,&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;Is there a way to control annotations in the the annotatePeak function?  For instance I would like to ignore &amp;ldquo;downstream&amp;rdquo; and consider those peaks &amp;ldquo;intergenic&amp;rdquo;.  Or for instance combine &amp;ldquo;1st exon&amp;rdquo; with &amp;ldquo;other exon&amp;rdquo; so there is one category of &amp;ldquo;exon&amp;rdquo;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;Any help would be great, thanks for doing this!&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;-Andrew&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;a href=&#34;https://support.bioconductor.org/p/104676/&#34;&gt;https://support.bioconductor.org/p/104676/&lt;/a&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>2017每月阅读量最高文章盘点</title>
      <link>https://guangchuangyu.github.io/2018/12/2017-biobabble/</link>
      <pubDate>Sat, 29 Dec 2018 16:20:43 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/12/2017-biobabble/</guid>
      <description>&lt;p&gt;这个公众号开始于2016年11月，2016年基本上阅读量都在一两百之间而已，就直接无视了吧。2018年写了每月最高阅读量的文章，2017年顺道也总结一下吧。好文总是值得再次阅读。&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;1. 《&lt;a href=&#34;https://mp.weixin.qq.com/s/IzSC1GnNPUwKdehhz-U8fQ&#34;&gt;Ask me anything about ggtree&lt;/a&gt;》&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;1月份，得知&lt;code&gt;ggtree&lt;/code&gt;的文章发表了，写了这篇，欢迎大家向我提问，我有问必答。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>2018每月阅读量最高文章盘点</title>
      <link>https://guangchuangyu.github.io/2018/12/2018-biobabble/</link>
      <pubDate>Sat, 29 Dec 2018 15:20:43 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/12/2018-biobabble/</guid>
      <description>&lt;p&gt;正如我在《&lt;a href=&#34;https://mp.weixin.qq.com/s/yJ1QLnsVqLrOY4GTsXEnrA&#34;&gt;我想学习&lt;/a&gt;》一文中对朋友圈和公众号的吐槽一样。我翻看了2018年一整年中每个月最高阅读量的文章，我发现八卦和追热点的文章，通常阅读量不会太差，反而是我用心去写的技术类文章，反倒是阅读量很惨，不管怎样，我还是会继续写技术类文章，特别是关于我的R包的文章，大家在学会的同时，也可以触类旁通学会R和其它的R包。写R包就是希望大家做分析更方便一点，而写文档就是希望可以减少大家使用R包的障碍，当然也希望大家可以多多分享这样的努力！&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;1. 《&lt;a href=&#34;https://mp.weixin.qq.com/s/RK1CYEboiEDzapdHsiwEGg&#34;&gt;2018最新可用的sci-hub镜像+桌面版程序&lt;/a&gt;》&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;sci-hub经常换域名，1月份的时候，收集了一些，同时为苹果系统打包了windows程序，可以一键下文献。当然现在我们不用发这样的文章了，因为域名随时可以查，《&lt;a href=&#34;https://mp.weixin.qq.com/s/puPvCOQcOf7aG5ghY82XrQ&#34;&gt;Sci-Hub可用域名实时追踪&lt;/a&gt;》，又因为比桌面版程序更好用的浏览器按钮，《&lt;a href=&#34;https://mp.weixin.qq.com/s/6qmI0MI9vlwvxoXJuVl0sQ&#34;&gt;关于scihub，一文就够了&lt;/a&gt;》。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>R的交互与脚本模式</title>
      <link>https://guangchuangyu.github.io/2018/11/r-interactive/</link>
      <pubDate>Wed, 28 Nov 2018 11:08:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/11/r-interactive/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;抛出一个话题，R是不是有个大坑，在自动化脚本中(或者在循环中)，某些脚本执行会不出结果，特别是作图脚本。ps:分步执行可以出图&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;其实看我公众号的各位读者们，你们不应该有这个问题，如果有，那么证明我的文章没有好好看！&lt;/p&gt;
&lt;p&gt;有两篇很重要的文章《&lt;a href=&#34;http://mp.weixin.qq.com/s/BPY4dPFrrNrDKccMvax07w&#34;&gt;扪心自问，meme几何？&lt;/a&gt;》和《&lt;a href=&#34;http://mp.weixin.qq.com/s/Uhx3l3lKQS88OJ4SHntkNg&#34;&gt;树变图，图变树？&lt;/a&gt;》，特别是第二篇，和这个问题息息相关。&lt;/p&gt;
&lt;p&gt;首先假设我们有一个图：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;require(ggplot2)
p = qplot(1:10)
&lt;/code&gt;&lt;/pre&gt;&lt;h3 id=&#34;为什么在终端打p可以出图&#34;&gt;为什么在终端打p可以出图？&lt;/h3&gt;
&lt;p&gt;因为在R里，所有都是&lt;code&gt;对象&lt;/code&gt;，而在终端里你输入一个对象回车，R会去找相应的&lt;code&gt;方法&lt;/code&gt;去打印出来，如果是&lt;code&gt;S3&lt;/code&gt;对象，会去寻找&lt;code&gt;print&lt;/code&gt;方法，而如果是&lt;code&gt;S4&lt;/code&gt;会去找&lt;code&gt;show&lt;/code&gt;方法。&lt;/p&gt;
&lt;p&gt;所以你在终端里打&lt;code&gt;p&lt;/code&gt;，其实等同于你打&lt;code&gt;print(p)&lt;/code&gt;，它其实调用了&lt;code&gt;ggplot2:::print.ggplot&lt;/code&gt;，&lt;/p&gt;
&lt;p&gt;你打&lt;code&gt;plot(p)&lt;/code&gt;也可以，如果你看过代码的话，画图这个动作是定义在&lt;code&gt;plot.ggplot&lt;/code&gt;方法里的，而&lt;code&gt;print.ggplot &amp;lt;- plot.ggplot&lt;/code&gt;。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>MacBook安装Arch的一些设置</title>
      <link>https://guangchuangyu.github.io/2018/11/macbook-arch-setting/</link>
      <pubDate>Mon, 26 Nov 2018 00:22:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/11/macbook-arch-setting/</guid>
      <description>&lt;h2 id=&#34;声音&#34;&gt;声音&lt;/h2&gt;
&lt;p&gt;没有声音，在&lt;code&gt;/etc/modprobe.d/modprobe.conf&lt;/code&gt;里加入：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;options snd-hda-intel model=mbp3 position_fix=2
&lt;/code&gt;&lt;/pre&gt;&lt;h2 id=&#34;网络&#34;&gt;网络&lt;/h2&gt;
&lt;p&gt;dhcpcd禁止&lt;code&gt;ipv6&lt;/code&gt;:&lt;/p&gt;
&lt;p&gt;在&lt;code&gt;/etc/dhcpcd.conf&lt;/code&gt;中加入:&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;noipv6rs
noipv6
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>记一次搞死又搞活linux的经历</title>
      <link>https://guangchuangyu.github.io/2018/11/arch-lts/</link>
      <pubDate>Sun, 25 Nov 2018 10:44:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/11/arch-lts/</guid>
      <description>&lt;p&gt;看到一个帖子, &lt;a href=&#34;https://www.maketecheasier.com/make-arch-linux-more-stable/&#34;&gt;https://www.maketecheasier.com/make-arch-linux-more-stable/&lt;/a&gt;， 说避免老升级内核，用lts版，装完可以把原先内核干掉：&lt;/p&gt;
&lt;blockquote&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;sudo pacman -S linux-lts
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;When you’ve installed the LTS kernel, it’s a good idea to remove the bleeding edge kernel from your system.&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;sudo pacman -R linux 
&lt;/code&gt;&lt;/pre&gt;&lt;/blockquote&gt;
&lt;p&gt;我内心闪过一个想法，难道不用配置启动么？也没去确认，照做后重启，你妹啊，太坑了，直接就找不到内核死掉！&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>DOSE包引用过百</title>
      <link>https://guangchuangyu.github.io/2018/11/dose-citation-above-100/</link>
      <pubDate>Sun, 25 Nov 2018 01:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/11/dose-citation-above-100/</guid>
      <description>Disease ontology (DO) annotates human genes in the context of disease. DO is important annotation in translating molecular findings from high-throughput data to clinical relevance. DOSE is an R package providing semantic similarity computations among DO terms and genes which allows biologists to explore the similarities of diseases and of gene functions in disease perspective. Enrichment analyses including hypergeometric model and gene set enrichment analysis are also implemented to support discovering disease associations of high-throughput biological data.</description>
    </item>
    
    <item>
      <title>如何定义基因下游的区间</title>
      <link>https://guangchuangyu.github.io/2018/11/how-to-define-downstream-range/</link>
      <pubDate>Thu, 22 Nov 2018 12:20:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/11/how-to-define-downstream-range/</guid>
      <description>&lt;p&gt;首先基因下游是什么？&lt;/p&gt;
&lt;p&gt;我们知道上游很重要啊，因为可能会调控转录，但注释的时候，没有上游这个东西，为什么呢？因为转录起始位点TSS的上下游被定义为promoter，所以啊上游被包括在promoter中，也就没有上游这个category了。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>转换UpSet图为ggplot对象</title>
      <link>https://guangchuangyu.github.io/2018/11/upset-to-ggplot/</link>
      <pubDate>Sun, 11 Nov 2018 23:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/11/upset-to-ggplot/</guid>
      <description>&lt;p&gt;我在2018年4月份的一条推特文，&lt;a href=&#34;https://twitter.com/guangchuangyu/status/988672880551518210&#34;&gt;https://twitter.com/guangchuangyu/status/988672880551518210&lt;/a&gt;，可以把&lt;code&gt;UpSetR&lt;/code&gt;变成&lt;code&gt;ggplot&lt;/code&gt;然后可以各种玩，比较我在推特文中所展示的，图上嵌入venn图、使用&lt;code&gt;cowplot&lt;/code&gt;拼图等。然而过了大半年，我的&lt;a href=&#34;https://github.com/hms-dbmi/UpSetR/pull/112&#34;&gt;pull request&lt;/a&gt;并没有被作者接收，也就是说这功能还不存在于官方的版本中。&lt;/p&gt;
&lt;p&gt;如果有兴趣的话，应该安装我fork的版本。&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;devtools::install_github(&amp;quot;GuangchuangYu/UpSetR&amp;quot;)
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>（翻）云（覆）雨图</title>
      <link>https://guangchuangyu.github.io/2018/11/raincloud/</link>
      <pubDate>Fri, 09 Nov 2018 12:21:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/11/raincloud/</guid>
      <description>&lt;p&gt;生物狗喜欢画barplot，但毕竟只有均值和标准误差信息量太低，万一有outliers呢？万一不是正态分布呢？所以就吐槽了又吐槽，但大家还是乐此不疲，因为大家都在用，因为很多人只会画barplot，所以产生各种反barplot运动，并呼吁大家使用&lt;a href=&#34;http://mp.weixin.qq.com/s/kk3M1eoVhCiYmyu92P0zwA&#34;&gt;boxplot&lt;/a&gt;，boxplot有四分位数的统计量，可以反应outlier和数据的分布，比barplot高得多了。&lt;/p&gt;
&lt;p&gt;然而事情是不断在进化的，我们的手段是要跟上潮流的，现在的潮流就是除了要有统计量，还要有原始数据，甚至于有统计推断，全集中一图中，揭开数据的红盖头，给大家呈现全方位无死角的面貌。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>设置可视化窗口</title>
      <link>https://guangchuangyu.github.io/2018/11/%E8%AE%BE%E7%BD%AE%E5%8F%AF%E8%A7%86%E5%8C%96%E7%AA%97%E5%8F%A3/</link>
      <pubDate>Tue, 06 Nov 2018 10:23:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/11/%E8%AE%BE%E7%BD%AE%E5%8F%AF%E8%A7%86%E5%8C%96%E7%AA%97%E5%8F%A3/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/Bioconductor/ggtree/cartesian/1148940491.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;小伙伴发来这个图，问我是不是&lt;code&gt;bug&lt;/code&gt;，这真是犯了程序员的社交礼仪。&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;你如果对一个程序员说，“你的代码有bug。”
他的第一反应是：&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;ol&gt;
&lt;li&gt;你的环境有问题吧&lt;/li&gt;
&lt;/ol&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;ol start=&#34;2&#34;&gt;
&lt;li&gt;傻逼你会用吗。&lt;/li&gt;
&lt;/ol&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;如果你委婉地说：“你这个程序和预期的有点不一致，你看看是不是我的使用方法有问题。”&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;他本能地会想：“操，是不是出bug了！”&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;这显然不是&lt;code&gt;bug&lt;/code&gt;，这是绝大多数人对&lt;code&gt;ggplot2&lt;/code&gt;的误解，他们认为用&lt;code&gt;xlim&lt;/code&gt;和&lt;code&gt;ylim&lt;/code&gt;是放置一个窗口去看你的图，然而在&lt;code&gt;ggplot2&lt;/code&gt;是限定一个窗口去过滤你的数据，并重新画图！你的数据被过滤了！如果是放置窗口在图上，一条线从A到B，如果B在窗口之外，那么线被截断了，你看到半条线，但如果是过滤数据呢？B不复存在，那么线条A到B也不复存在，没有B，A到B的线画不出来。就是这样，所以这绝逼不是&lt;code&gt;bug&lt;/code&gt;，而是程序员本能反应的第二种情况，你用错了。&lt;/p&gt;
&lt;p&gt;那么怎么样不过滤数据，而只是设置可视化窗口呢？你基本上很少看到有人这么用，因为几乎99%的人都只知道&lt;code&gt;xlim&lt;/code&gt;和&lt;code&gt;ylim&lt;/code&gt;，一般人我也不告诉他，快点拿去小抄把下面的代码记录一下。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>王八拳编程及其它</title>
      <link>https://guangchuangyu.github.io/2018/11/un-abstract-coding/</link>
      <pubDate>Mon, 05 Nov 2018 10:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/11/un-abstract-coding/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://gss3.bdstatic.com/-Po3dSag_xI4khGkpoWK1HF6hhy/baike/s%3D220/sign=3083f8d5d30735fa95f049bbae530f9f/dbb44aed2e738bd42887e8ffa68b87d6267ff95e.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;h3 id=&#34;什么是王八拳&#34;&gt;什么是王八拳&lt;/h3&gt;
&lt;blockquote&gt;
&lt;p&gt;王八拳是四肢生物，包括人类天生会的一种本能打斗方式，男女都会，老少皆宜。 &amp;ndash; 百度百科&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;显然从定义上来看，这是一套在人类存在以前早已有之的古拳法，当然做为人类我们还是希望找到人类创始的起源，给人类找一点体面。&lt;/p&gt;
&lt;p&gt;据(百度百科)说，有三种可疑的起源说法：&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;起源一：王朔的《看上去很美》中学会的一种中国古拳法。这种拳一般流行于幼儿园中，打这种拳，讲究的是打拳的小朋友眼睛紧闭，双拳握紧，两条胳膊以肩为圆心，向前乱轮圆圈，远里看就象乌龟爬坡爬不上去乱蹬的那个样子。这种拳一般不以击中目标为目的，主要是以一种盲目的抡拳动作在气势上威吓对你有攻击企图的小朋友。而如果打拳者在使出这种拳法的时候拌以大声的哭叫，更可以极大的增加威吓对方的力量。&lt;/li&gt;
&lt;li&gt;起源二：一夫多妻制的中国农村妇女发明的一种古拳法，起源于于公元前5世纪，具有广泛的妇女基础，王八拳吸取了猴、狗、猪诸拳种之长，把形意拳的手法、手型、步型、步法、腿法、平衡、跳跃等动作规格化。它的特点是姿势绝不优美，动作绝不快捷，出手阴，跳得低，蹦得不远。它的内容包括挠、掐、咬三种动作，还有一定数量的击打敌人下三路的跳跃、跌仆、滚翻动作。长拳在技术上有八点要求：①姿势。头正，颈直，沉肩，挺胸，直腰，敛臀，上肢舒展、挺拔，下肢稳定、匀称。②动作。在做踢、打、摔、拿等技击动作时，起止点、路线、力点都要清晰。&lt;/li&gt;
&lt;li&gt;起源三：巴塞罗那奥运会前，朱时茂和陈佩斯的表演的著名小品中，“陈小二”以一轮凶残猛烈的正反王八拳与当时的“拳王”朱时茂战成平手，并相约巴塞罗那再战。也正是因为这经典的一战，王八拳才被百姓所熟知。&lt;/li&gt;
&lt;/ul&gt;</description>
    </item>
    
    <item>
      <title>msigdf &#43; clusterProfiler全方位支持MSigDb</title>
      <link>https://guangchuangyu.github.io/2018/11/msigdf_clusterprofiler/</link>
      <pubDate>Thu, 01 Nov 2018 12:21:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/11/msigdf_clusterprofiler/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/Bioconductor/clusterProfiler/msigdf.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;生信界的网红Stephen Turner在github上有个&lt;code&gt;msigdf&lt;/code&gt;的包，我在他写这个包的时候，就写了个&lt;code&gt;gist&lt;/code&gt;，连接&lt;code&gt;clusterProfiler&lt;/code&gt;，我写&lt;code&gt;gist&lt;/code&gt;的时候是2016年的8月，很高兴网红还惦记着我的&lt;code&gt;gist&lt;/code&gt;。&lt;/p&gt;
&lt;p&gt;&lt;code&gt;msigdf&lt;/code&gt;这个包把著名的Broad Institute著名的Molecular Signatures Database (MSigDB)数据以data frame的形式打包成&lt;code&gt;R&lt;/code&gt;包，这样子非常方便使用，当然他后来没有更新，而一个fork的版本，&lt;code&gt;ToledoEM/msigdf&lt;/code&gt;把数据更新为最新版本v6.2，发布于2018年7月。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>给硕博考生的一封信</title>
      <link>https://guangchuangyu.github.io/2018/10/for-postgraduate-student/</link>
      <pubDate>Thu, 18 Oct 2018 16:30:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/10/for-postgraduate-student/</guid>
      <description>&lt;h3 id=&#34;研究生是考出来的博士生是联系出来的&#34;&gt;研究生是考出来的，博士生是联系出来的！&lt;/h3&gt;
&lt;p&gt;这句话早在10年前我一个师兄就告诉我。早在2006年我去上生面试的时候，我就发现已经有考生早就在实验室干了。反正我当年是fail了，然后我为何没能调剂到军事医学科学院，因为06年的时候，正是裁军的时候，军医科的名额很少，而导师手下也有一名同学初试过了，而且已经在实验室干了一年，名额必须给他。&lt;/p&gt;
&lt;p&gt;所以在此处，我想跟大家说，十多年前尚且如此，现在行情只会更差，研究生也要联系了！&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>画图倒不如手绘</title>
      <link>https://guangchuangyu.github.io/2018/10/ggrough/</link>
      <pubDate>Mon, 15 Oct 2018 00:21:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/10/ggrough/</guid>
      <description>&lt;p&gt;在《&lt;a href=&#34;http://mp.weixin.qq.com/s/P7yUFLwW4OLGBrPw05iQ_A&#34;&gt;漫画版的进化树你见过吗？&lt;/a&gt;》一文中，我介绍过一个R包，可以把&lt;code&gt;ggplot2&lt;/code&gt;转成漫画风格，今天介绍一个新的包，&lt;code&gt;ggrough&lt;/code&gt;，它封装了一个叫&lt;code&gt;roughjs&lt;/code&gt;的javascript库，可以把&lt;code&gt;ggplot2&lt;/code&gt;转成手绘风格：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;require(dplyr)
library(ggplot2)
count(mtcars, carb) %&amp;gt;%
  ggplot(aes(carb, n)) +
  geom_col() + 
  labs(title=&amp;quot;Number of cars by carburator count&amp;quot;) + 
  theme_grey(base_size = 16) -&amp;gt; p 
p
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>做学术终究是看脸...</title>
      <link>https://guangchuangyu.github.io/2018/10/gorilla-vs-clusterprofiler/</link>
      <pubDate>Tue, 09 Oct 2018 13:12:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/10/gorilla-vs-clusterprofiler/</guid>
      <description>&lt;p&gt;做科研我们不爽的是没有结果，比结果更不爽的是结果不符合预期，故事不知道该怎么编，然而戏真的不要太多，学术不是以预期来驱动的，请尊重一下事实，还有你的小鼠。&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;we had a quick email exchange about this and I would like to report this. (I appologise for contacting you directly, rather than following the submission guideline). I have a dataset with 6166 proteins of which 201 proteins are upregulated. The problem is that specifying the background proteins using universe argument in clusterProfiler, decreases the number of significant GO categories (28 significant categories without the universe argument and 5 with this argument). At the same time when I use online GORILLA tool  I get a lot of categories, with the background:&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;a href=&#34;http://cbl-gorilla.cs.technion.ac.il/GOrilla/kwpgie9l/GOResults.html&#34;&gt;http://cbl-gorilla.cs.technion.ac.il/GOrilla/kwpgie9l/GOResults.html&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;and not categories without the background:&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;a href=&#34;http://cbl-gorilla.cs.technion.ac.il/GOrilla/5y4n3hn1/GOResults.html&#34;&gt;http://cbl-gorilla.cs.technion.ac.il/GOrilla/5y4n3hn1/GOResults.html&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;I am not sure whether this is a bug or not, so I decided to report it here&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;The dataset is presented below 
&amp;hellip;&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;allProtUGO &amp;lt;- enrichGO(gene = upRegProt, OrgDb = org.Hs.eg.db,  keyType = &amp;quot;UNIPROT&amp;quot;,  ont=&#39;ALL&#39;, pool = TRUE, 
&lt;/code&gt;&lt;/pre&gt;&lt;/blockquote&gt;
&lt;pre&gt;&lt;code&gt;                   qvalueCutoff = 0.05)
&lt;/code&gt;&lt;/pre&gt;
&lt;blockquote&gt;
&lt;p&gt;identifiedProtUGO &amp;lt;- enrichGO(gene = upRegProt, OrgDb = org.Hs.eg.db,  keyType = &amp;ldquo;UNIPROT&amp;rdquo;,  ont=&amp;lsquo;ALL&amp;rsquo;, pool = TRUE, 
qvalueCutoff = 0.05,  universe = backgroundProt)&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;dim (allProtUGO@result)
dim (identifiedProtUGO@result)&lt;/p&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>一次解决所有代理问题</title>
      <link>https://guangchuangyu.github.io/2018/09/proxychains/</link>
      <pubDate>Sun, 30 Sep 2018 10:30:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/09/proxychains/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;之前公众号上有人说，我回大陆了会有一波科学上网的教程，今天的推文算一个吧。真的是被你们言中了！&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;做为Bioconductor包作者，而&lt;code&gt;git push&lt;/code&gt;传代码到Bioconductor上是被封的。这很是恼火，随着10月份将迎来新一版本的Bioconductor发布，不能够push代码是多么惨的一件事。&lt;/p&gt;
&lt;p&gt;代理其实也挺恼火的，因为各种协议啊，你要各种设置啊，&lt;code&gt;http/https/ssh/git&lt;/code&gt;都是各种配置，其实我只要有一个&lt;code&gt;socks5&lt;/code&gt;的代理，然后你们所有需要走代理的程序都通过它就好了。&lt;/p&gt;
&lt;p&gt;谁特么有空天天在琢磨怎么配置各种不同协议的代理！只要我们想得到的，一般都有人做了。&lt;/p&gt;
&lt;p&gt;于是万能的github上找到了&lt;a href=&#34;https://github.com/haad/proxychains&#34;&gt;proxychains&lt;/a&gt;。&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;A hook preloader that allows to redirect TCP traffic of existing
dynamically linked programs through one or more SOCKS or HTTP
proxies
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;它强制给定程序发起的TCP连接通过事先配置的代理。可以涵盖所有需要代理的情景。就以git为例，没有proxychains的话，就必须为每个协议（&lt;code&gt;https&lt;/code&gt;, &lt;code&gt;git&lt;/code&gt;, &lt;code&gt;ssh&lt;/code&gt;）按照git文档的要求分别设置代理，过程复杂且不稳定。有了&lt;code&gt;proxychains&lt;/code&gt;，这些完全可以不用管，当然应用场景不限于&lt;code&gt;git&lt;/code&gt;，任何一个需要代理的命令行程序都是一样在运行的指令前面加&lt;code&gt;proxychains&lt;/code&gt;完事。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>不用biocLite安装Bioconductor包</title>
      <link>https://guangchuangyu.github.io/2018/09/install-bioconductor-package/</link>
      <pubDate>Tue, 18 Sep 2018 13:21:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/09/install-bioconductor-package/</guid>
      <description>&lt;p&gt;Bioconductor包的标准安装方法是：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;source(&amp;quot;https://bioconductor.org/biocLite.R&amp;quot;)
biocLite(pkg_name)
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;这其实是非常不好的，多年以来，一直没有改进，试想一下，bioconductor的网站如果被人黑了，放一段危险的代码，然后你却傻傻地去&lt;code&gt;source&lt;/code&gt;它，真的是画面太美！&lt;/p&gt;
&lt;p&gt;Bioconductor终于是想要改变了，往CRAN上扔了一个叫&lt;code&gt;BiocManager&lt;/code&gt;的包，以后通过CRAN安装这个包，再通过这个包来安装Bioconductor的包，显得安全多了，也不用大家费辣么多口水说你得先&lt;code&gt;source&lt;/code&gt;一段网上的代码，当然这个&lt;code&gt;BiocManager&lt;/code&gt;还不成熟，起码还没有在&lt;code&gt;BiocInstaller&lt;/code&gt;加载的时候提示大家转而用&lt;code&gt;BiocManager&lt;/code&gt;，也没有在Bioconductor的网页上介绍使用它来安装。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>用facet_labeller改facet_plot的panel名</title>
      <link>https://guangchuangyu.github.io/2018/09/facet_labeller/</link>
      <pubDate>Tue, 11 Sep 2018 13:17:48 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/09/facet_labeller/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;I post this because I am facing the same problem: I want to change the text of the label (not the font, the face, the colour, etc: the text itself) of the leftmost panel which is automatically called &amp;ldquo;Tree&amp;rdquo; by ggtree. As far as I understand, and contrary to what is posted below, the &amp;ldquo;theme&amp;rdquo; thing of ggplot2 only allows to change the appearance of the panel header, not the text of the panel title itself&amp;hellip; So how to go about that?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;这是&lt;a href=&#34;https://groups.google.com/d/msgid/bioc-ggtree/154a6acc-bf78-40d9-ad95-8dc1877a4f97%40googlegroups.com?utm_medium=email&amp;amp;utm_source=footer&#34;&gt;google group&lt;/a&gt;里的问题，说的是&lt;code&gt;facet_plot&lt;/code&gt;会把画树的panel叫做Tree，而他想改名，于是我就写了一个函数，&lt;code&gt;facet_labeller&lt;/code&gt;来回应这个问题。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>separating legends of heatmaps in ggtree</title>
      <link>https://guangchuangyu.github.io/2018/09/separating-legends-of-heatmaps-in-ggtree/</link>
      <pubDate>Mon, 10 Sep 2018 11:00:08 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/09/separating-legends-of-heatmaps-in-ggtree/</guid>
      <description>
&lt;script src=&#34;https://guangchuangyu.github.io/rmarkdown-libs/header-attrs/header-attrs.js&#34;&gt;&lt;/script&gt;


&lt;blockquote&gt;
&lt;p&gt;I’ve been having great success with ggtree now and have recommended it to several colleages here in Oxford.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;Is there any way to seperate the legend in heatmaps? Eg I have plotted a tree in a circular style with outer rings given extra data - I would like a seperate key for each ring - is this possible?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;This is a user question. Plotting multiple heatmaps that align to the phylogenetic tree is easy with &lt;code&gt;gheatmap&lt;/code&gt; function.&lt;/p&gt;
&lt;p&gt;Here is a simple example:&lt;/p&gt;
&lt;pre class=&#34;r&#34;&gt;&lt;code&gt;library(&amp;quot;ggplot2&amp;quot;)
library(&amp;quot;ggtree&amp;quot;)

nwk &amp;lt;- system.file(&amp;quot;extdata&amp;quot;, &amp;quot;sample.nwk&amp;quot;, package=&amp;quot;treeio&amp;quot;)

tree &amp;lt;- read.tree(nwk)
circ &amp;lt;- ggtree(tree, layout = &amp;quot;circular&amp;quot;)

df &amp;lt;- data.frame(first=c(&amp;quot;a&amp;quot;, &amp;quot;b&amp;quot;, &amp;quot;a&amp;quot;, &amp;quot;c&amp;quot;, &amp;quot;d&amp;quot;, &amp;quot;d&amp;quot;, &amp;quot;a&amp;quot;, &amp;quot;b&amp;quot;, &amp;quot;e&amp;quot;, &amp;quot;e&amp;quot;, &amp;quot;f&amp;quot;, &amp;quot;c&amp;quot;, &amp;quot;f&amp;quot;),
                 second= c(&amp;quot;z&amp;quot;, &amp;quot;z&amp;quot;, &amp;quot;z&amp;quot;, &amp;quot;z&amp;quot;, &amp;quot;y&amp;quot;, &amp;quot;y&amp;quot;, &amp;quot;y&amp;quot;, &amp;quot;y&amp;quot;, &amp;quot;x&amp;quot;, &amp;quot;x&amp;quot;, &amp;quot;x&amp;quot;, &amp;quot;a&amp;quot;, &amp;quot;a&amp;quot;))

rownames(df) &amp;lt;- tree$tip.label


p1 &amp;lt;- gheatmap(circ, df[, &amp;quot;first&amp;quot;, drop=F], offset=.8, width=.1,
               colnames_angle=90, colnames_offset_y = .25)
p2 &amp;lt;- gheatmap(p1, df[, &amp;quot;second&amp;quot;, drop=F], offset=5, width=.1,
               colnames_angle=90, colnames_offset_y = .25)&lt;/code&gt;&lt;/pre&gt;
</description>
    </item>
    
    <item>
      <title>用ggplot2画3D</title>
      <link>https://guangchuangyu.github.io/2018/08/ggplot-3d/</link>
      <pubDate>Mon, 13 Aug 2018 18:30:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/08/ggplot-3d/</guid>
      <description>&lt;p&gt;在《&lt;a href=&#34;http://mp.weixin.qq.com/s/BPY4dPFrrNrDKccMvax07w&#34;&gt;扪心自问，meme几何？&lt;/a&gt;》一文中，我画了一只兔子，今天给大家演示一下画一只3D版本的兔子，我们知道&lt;code&gt;ggplot2&lt;/code&gt;不支持3D，只能画2D的图，但3D其实只是视觉上的，显示在你屏幕上的，同样只是2D。所以我们要做的，就是把3D的坐标转换成2D，然后画出2D的图片来，而这2D看上去有3D的效果。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Arch之软件降级</title>
      <link>https://guangchuangyu.github.io/2018/08/arch-downgrade/</link>
      <pubDate>Wed, 08 Aug 2018 20:10:35 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/08/arch-downgrade/</guid>
      <description>&lt;p&gt;用Arch Linux就是每天睡觉关机前滚一下，然而有时候有些软件升级滚出问题，比如&lt;code&gt;glibc-2.28&lt;/code&gt;就导致了&lt;code&gt;R&lt;/code&gt;安装包有问题，会抛出下面的错误：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;terminate called after throwing an instance of &#39;std::runtime_error&#39;
  what():  Mutex creation failed
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;用&lt;code&gt;blogdown&lt;/code&gt;编译博客也同样会抛出这个错误。&lt;/p&gt;
&lt;p&gt;然后&lt;code&gt;electron&lt;/code&gt;也有问题，《&lt;a href=&#34;http://mp.weixin.qq.com/s/L556YNtVSKf84cEFdEZVBQ&#34;&gt;开源的macOS和linux版微信&lt;/a&gt;》跑着跑着突然CPU就狂飙。&lt;/p&gt;
&lt;p&gt;解决办法就是安装回老版本，但&lt;code&gt;pacman&lt;/code&gt;永远是最新的，当然可以去git/svn仓库里找老版本的&lt;code&gt;PKGBUILD&lt;/code&gt;，然后再&lt;code&gt;makepkg&lt;/code&gt;，但经常会在&lt;code&gt;signature checking&lt;/code&gt;这步报错，你还得到导入&lt;code&gt;keyring&lt;/code&gt;，挺麻烦。&lt;/p&gt;
&lt;p&gt;这时候我找到了&lt;code&gt;downgrade&lt;/code&gt;脚本:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Bash script for downgrading one or more packages to a version in your cache or the A.L.A.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;AUR有收录，安装非常简单：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>pheatmap类属性：一个更好用的pheatmap</title>
      <link>https://guangchuangyu.github.io/2018/08/pheatmap-class/</link>
      <pubDate>Mon, 06 Aug 2018 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/08/pheatmap-class/</guid>
      <description>&lt;p&gt;&lt;code&gt;pheatmap&lt;/code&gt;我其实用的次数不多，但在帮别人解决一些问题之后，比如：&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;http://mp.weixin.qq.com/s/Xhi_ZkrEzUVdnCu7ECBS4w&#34;&gt;听说你还不会画热图&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s/yVLgGQQi0CQ9Q9UfIKl5aA&#34;&gt;不同数据集画出的热图，用同样的颜色区间上色?&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;我发现这包的交互能力是比较差的，它就像传统的&lt;code&gt;plot&lt;/code&gt;函数一样，命令一打下去，就直接画图，虽然它其实是有输出的，但事实上超出了一般用户的理解能力，它的输出，比如说可以用&lt;code&gt;cowplot&lt;/code&gt;来拼图，我在上面链接的那篇文章中皆来演示，然而很多人问我，怎么把&lt;code&gt;pheatmap&lt;/code&gt;画的热图和&lt;code&gt;ggplot2&lt;/code&gt;的图，用&lt;code&gt;cowplot&lt;/code&gt;来拼。这就是因为拼图的方法超出了很多的理解范围，看过演示，也只能照猫画老虎，过后也就忘记了。有没有办法用大家可以理解的方法来拼？这样就不太容易忘记，答案是肯定的，我下次再讲。今天先讲一讲其前提条件。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>酗酒的Linux不是好企鹅</title>
      <link>https://guangchuangyu.github.io/2018/07/linux_qq/</link>
      <pubDate>Sun, 22 Jul 2018 04:30:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/07/linux_qq/</guid>
      <description>&lt;p&gt;国内的办公环境，离不开QQ等Windows软件，以前我通过《&lt;a href=&#34;http://mp.weixin.qq.com/s/7AdkrX3hZYdKNP4YIhgZLA&#34;&gt;安装黑苹果&lt;/a&gt;》来解决，如果要用Linux呢？我们不禁想问，&lt;a href=&#34;https://solarianprogrammer.com/2017/04/16/windows-susbsystem-for-linux-xfce-4/&#34;&gt;连Windows都能跑Linux程序了&lt;/a&gt;，Linux到底什么时候能跑Windows程序？&lt;/p&gt;
&lt;h2 id=&#34;干了这杯酒不干没鸡鸡&#34;&gt;干了这杯酒，不干没鸡鸡！&lt;/h2&gt;
&lt;p&gt;&lt;img src=&#34;https://lh3.googleusercontent.com/-dfDJJYSQ4MM/V-PSb7LmfPI/AAAAAAAAEy8/EXNlBjf7GZI_aAfC-lwQx2bHkppC5ereQCJoC/w530-h530-n-rw/e446d718-5ca4-42ec-8d59-45f4630b211d&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;Wine虽然是一个解决方案，而且现在也有现成的方案，比如《&lt;a href=&#34;http://mp.weixin.qq.com/s/4yWzHxjB9WL33ujagi5BAw&#34;&gt;你们想要的：QQ跑在Linux上&lt;/a&gt; 》，再比如有打包好的深度QQ等。但我不想在我64位的系统里装一堆32位的兼容包，也不想（多多少少得）折腾Wine。&lt;/p&gt;
&lt;h2 id=&#34;无需安装开箱即用&#34;&gt;无需安装，开箱即用？&lt;/h2&gt;
&lt;p&gt;这显然是最好的方案，比如在苹果系统上，我已经打包了《&lt;a href=&#34;http://mp.weixin.qq.com/s/F0TxMk1CrYVNvxWqZgv-Aw&#34;&gt;OSX版BioEdit&lt;/a&gt;》和《&lt;a href=&#34;https://mp.weixin.qq.com/s/P3WhPkTrf2dUkzvOba3hlQ&#34;&gt;独家：SciHub苹果桌面版&lt;/a&gt;》，你只需要拖到&lt;code&gt;Applications&lt;/code&gt;里，双击就能用。&lt;/p&gt;
&lt;p&gt;这有什么好处？第一你不用去系统里装Wine以及一堆依赖包，第二你不需要去配置Wine，第三这个运行环境是与你的系统分离的（系统是干净的）。对于用户来说，傻瓜化开箱即用，对于系统来说，干净不影响。这是最好的方案。谁愿意去装一堆没用的兼容&lt;code&gt;libs&lt;/code&gt;，谁愿意去折腾老半天还用不上！当然有一点点不好的地方，是打包的软件体积稍大一点，因为你要打包整个运行环境嘛，但现在最不值钱的就是存储空间了。&lt;/p&gt;
&lt;p&gt;所以最好的方案是像Mac这样，可以把运行环境分离出来，系统干净不折腾！当然再者还得有像我这样的好心人去打包。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>R总给我惊喜</title>
      <link>https://guangchuangyu.github.io/2018/07/partial-match-when-subsetting-rowname-of-data-frame/</link>
      <pubDate>Wed, 11 Jul 2018 13:20:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/07/partial-match-when-subsetting-rowname-of-data-frame/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Hello!
First of all, I would like to thank you for this wonderful and very powerful package!&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;I have tried to plot a phylogenetic tree with heatmap of associated matrix (with &lt;code&gt;gheatmap&lt;/code&gt;).
I found that the row names of matrix doesn&amp;rsquo;t exactly match to the tip names of tree in case if there is missing data in associated matrix.
In other words, if we have two species (e.g., Species&lt;strong&gt;198&lt;/strong&gt; and Species&lt;strong&gt;1981&lt;/strong&gt;), but only one of them is represented in the associated matrix, we will have colored cells for both species in the heatmap.&lt;/p&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>拟南芥的富集分析</title>
      <link>https://guangchuangyu.github.io/2018/07/clusterprofiler-ath/</link>
      <pubDate>Tue, 10 Jul 2018 15:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/07/clusterprofiler-ath/</guid>
      <description>&lt;p&gt;「知识星球」里的问题，&lt;a href=&#34;https://t.zsxq.com/aEyneA2&#34;&gt;https://t.zsxq.com/aEyneA2&lt;/a&gt;，拟南芥的ID怎么搞，这个内置是支持的。&lt;/p&gt;
&lt;p&gt;比如我随便搞几个ID来演示一下：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;&amp;gt; require(clusterProfiler)
Loading required package: clusterProfiler

clusterProfiler v3.9.0  For help: https://guangchuangyu.github.io/software/clusterProfiler

If you use clusterProfiler in published research, please cite:
Guangchuang Yu, Li-Gen Wang, Yanyan Han, Qing-Yu He. clusterProfiler: an R package for 
comparing biological themes among gene clusters. OMICS: A Journal of Integrative Biology. 2012, 16(5):284-287.

g &amp;lt;- c(&amp;quot;AT5G61600&amp;quot;, &amp;quot;AT2G44230&amp;quot;, &amp;quot;AT1G49130&amp;quot;, &amp;quot;AT1G30310&amp;quot;, &amp;quot;AT3G18560&amp;quot;,
&amp;quot;AT2G15960&amp;quot;, &amp;quot;AT2G29290&amp;quot;, &amp;quot;AT1G08930&amp;quot;, &amp;quot;AT2G44460&amp;quot;, &amp;quot;AT3G46600&amp;quot;,
&amp;quot;AT5G24380&amp;quot;, &amp;quot;AT3G59270&amp;quot;, &amp;quot;AT5G55780&amp;quot;, &amp;quot;AT2G45090&amp;quot;, &amp;quot;AT5G38430&amp;quot;,
&amp;quot;AT2G17040&amp;quot;, &amp;quot;AT4G35770&amp;quot;, &amp;quot;AT5G30341&amp;quot;, &amp;quot;AT1G56320&amp;quot;, &amp;quot;AT2G16367&amp;quot;)
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>scholar包检索期刊影响因子（2018年最新版本）</title>
      <link>https://guangchuangyu.github.io/2018/07/scholar-impact-factor/</link>
      <pubDate>Tue, 03 Jul 2018 15:22:35 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/07/scholar-impact-factor/</guid>
      <description>&lt;p&gt;在《&lt;a href=&#34;https://mp.weixin.qq.com/s/kBnLyNl2anXuMa6sDepRQw&#34;&gt;一个要复活的R包和一个404的网站&lt;/a&gt;》一文中第一次介绍了scholar包，它可以应用于《&lt;a href=&#34;https://mp.weixin.qq.com/s/IBrEOh92r_90DRbGb3XlKg&#34;&gt;自动抓取论文的引用数据&lt;/a&gt;》，虽然数据源来自于Google Scholar，国内用户可能访问不了，但今天要介绍的这个功能，所有人都是可以用的，它允许我们检索期刊的影响因子，在《&lt;a href=&#34;https://mp.weixin.qq.com/s/qnuiepL4-nSiSWJVJH54ug&#34;&gt;scholar包支持检索期刊影响因子&lt;/a&gt;》一文中第一次介绍了这个功能，当时是2016年的影响因子（2017年发布），现在数据已经更新至2018年6月26号发布的2017年影响因子。&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;&amp;gt; library(scholar)
&amp;gt; jn = c(&amp;quot;bioinformatics&amp;quot;, &amp;quot;methods in ecology and evolution&amp;quot;,
+     &amp;quot;molecular biosystems&amp;quot;, &amp;quot;molecular biology and evolution&amp;quot;)
&amp;gt; get_impactfactor(jn)
# A tibble: 4 x 4
  Journal                          Cites ImpactFactor Eigenfactor
  &amp;lt;chr&amp;gt;                            &amp;lt;dbl&amp;gt;        &amp;lt;dbl&amp;gt;       &amp;lt;dbl&amp;gt;
1 BIOINFORMATICS                   95300         5.48      0.201
2 Methods in Ecology and Evolution  8866         6.36      0.0370
3 Molecular BioSystems              7269         2.76      0.0175
4 MOLECULAR BIOLOGY AND EVOLUTION  44664        10.2       0.102
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>2018世界杯专属图层</title>
      <link>https://guangchuangyu.github.io/2018/06/geom_worldcup2018/</link>
      <pubDate>Tue, 19 Jun 2018 13:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/06/geom_worldcup2018/</guid>
      <description>&lt;p&gt;说到世界杯，我是不追的，但1998年法国世界杯我还是有印象的，那时候读初中的我，一直在集邮，那年代没有网购，通讯基本靠吼，当年的我已经是个老司机了，通过邮政汇款，买了好多东西，包括1998年世界杯从法国寄往中国的首日封，当然锁在老家的柜子里，尘封多年，所以我现在也没办法随手拍一张照片给大家分享。&lt;/p&gt;
&lt;p&gt;另一件事，同样是1998年，那年升高一，开学第一天，老师让大家自我介绍一下，有位帅哥在见面第一天，就立了flag，说自己中考没考好，是因为看世界杯了，他高考必定要怎么样怎么样，毕竟世界杯是四年一次。你一个交钱进学校的学渣，牛逼吹大了，我印象深刻，所以我后来留意了一下这家伙高考上了那家高校，结果是「中山大学网络教育学院」，也就是电视大学！真的是情节反转如疾风！&lt;/p&gt;
&lt;p&gt;《&lt;a href=&#34;https://mp.weixin.qq.com/s/EojwBbg0MUWijwGeNIjntg&#34;&gt;转发5个群，Y叔送你一顶帽子&lt;/a&gt;》这一篇文章写的是加圣诞帽子，但你要加个C罗、梅西，有什么差别吗？没有！你要加某球队的队服，有什么差别吗？没有。所以要制作世界杯专属头像，已然可以用ggimage纯代码生成。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggtree画根分支</title>
      <link>https://guangchuangyu.github.io/2018/06/root-edge/</link>
      <pubDate>Wed, 13 Jun 2018 11:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/06/root-edge/</guid>
      <description>&lt;p&gt;&lt;code&gt;ggtree&lt;/code&gt;画树是不带root edge的，之前在《&lt;a href=&#34;http://mp.weixin.qq.com/s/b0OVm2ZDGbEZ48O1Uyp_WA&#34;&gt;中空的环形树&lt;/a&gt;》一文中，有用户想要加长长的root edge，这样变成环形树的时候，就可以用这个root edge把树给顶出去，这个我给出的解决方案是留白，大家可以回过去看那篇文章。&lt;/p&gt;
&lt;p&gt;然而root edge在某些时候还是需要的，我其实也一直有要写的想法，不过因为不是特别需要的东西，一直也就放着，刚好最近有用户在feature request，想要画root edge，于是我就实现了&lt;code&gt;geom_rootedge&lt;/code&gt;图层，当你加这个图层的时候，root edge就自动画上去了。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>你是我的巧克力 - Windows包管理器Chocolatey</title>
      <link>https://guangchuangyu.github.io/2018/06/chocolatey/</link>
      <pubDate>Tue, 12 Jun 2018 12:15:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/06/chocolatey/</guid>
      <description>&lt;p&gt;试想一下，每次重装系统，都要安装一堆常用的小软件，7zip, notepad++, filezilla, winrar等等，每次都要搜索下载地址，下载，安装，摆明了是木兰要从军一般，“东市买骏马，西市买鞍鞯，南市买辔头，北市买长鞭”，当然Windows现在也有各种软件管家之类的软件，但很多是流氓软件，要带各种全家桶的，我宁愿自己来一次木兰从军记。&lt;/p&gt;
&lt;p&gt;大家都喜欢Linux的包管理，比如&lt;code&gt;apt-get&lt;/code&gt;，而OSX也有homebrew，可以brew install一大票Unix-like的软件，而Windows用户只有羡慕的份，上面提到的流氓软件管理，当然也是装不了Unix-like软件的，所以我们羡慕，我们妒忌，外加恨！&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;今天要跟大家介绍一个为windows设计的包管理器，Chocolatey，有了它，你也能&lt;code&gt;choco install wget&lt;/code&gt;, &lt;code&gt;choco install docker&lt;/code&gt;这样装软件了，不用再羡慕水果用户，不用再木兰从军般装软件了。&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Chocolatey is a package manager for Windows (like apt-get or yum but for Windows)&lt;/strong&gt;. It was designed to be a decentralized framework for quickly installing applications and tools that you need. It is built on the NuGet infrastructure currently using PowerShell as its focus for delivering packages from the distros to your door, err computer.&lt;/p&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>github被微软收购</title>
      <link>https://guangchuangyu.github.io/2018/06/github-ms-meme/</link>
      <pubDate>Tue, 05 Jun 2018 08:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/06/github-ms-meme/</guid>
      <description>&lt;p&gt;微软以75亿美元收购全球最大的单身交友网站GitHub，应景&lt;a href=&#34;https://mp.weixin.qq.com/s/koM3GU1zr8dE0S0fkdncxA&#34;&gt;分享一张图片&lt;/a&gt;，其实这图大家并不陌生，在《&lt;a href=&#34;http://mp.weixin.qq.com/s/Xhi_ZkrEzUVdnCu7ECBS4w&#34;&gt;听说你还不会画热图&lt;/a&gt;》一文中，大家早已见过。&lt;/p&gt;
&lt;p&gt;这图实在太好玩，被套在各种场景上，今天就要教大家怎么用R，纯代码生成这样的图，简直是吐槽神器。这类图可以归入meme，画meme，当然少不了我写的meme包，这包收录在CRAN中，点击下面链接了解一下：&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;http://mp.weixin.qq.com/s/jDXjkrkq_YVhW-Z5Vx2-Fg&#34;&gt;用R画meme ;)&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s/4b8enFCd_lLt278Ddxp3rg&#34;&gt;使用外部字体画meme&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://mp.weixin.qq.com/s/BPY4dPFrrNrDKccMvax07w&#34;&gt;扪心自问，meme几何？&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;</description>
    </item>
    
    <item>
      <title>Kopernio: 快速一键下文献</title>
      <link>https://guangchuangyu.github.io/2018/05/kopernio/</link>
      <pubDate>Thu, 31 May 2018 09:27:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/05/kopernio/</guid>
      <description>&lt;p&gt;kopernio是个浏览器插件，可以通过&lt;a href=&#34;http://kopernio.com/&#34;&gt;http://kopernio.com/&lt;/a&gt;获得，现在这类插件其实挺多，当然多半是结合sci-hub，而sci-hub也是下文献领域绝对的王者，而且很多插件还有额外的一些功能，比如显示影响因子之类的，甚至于还有些给加二维码，微信扫一扫直接把文章分享到朋友圈，反正是啥都有人干。所以虽然我知道这个插件已经很久了，我一直没有介绍它的原因就在于此，它似乎也并不出彩。&lt;/p&gt;
&lt;p&gt;但今天我要介绍它，因为当你打开它的主页时，你会发现赫然公布着一个消息：&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;We are excited to announce that Kopernio has joined Clarivate Analytics, the home of Web of Science and the Journal Impact Factor.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;它被Clarivate Analytics收购了，已经是Clarivate Analytics旗下的产品，这意味着以后可能会与Web of Science有更好的整合，它现在支持PubMed和Google Scholar，以后支持Web of Science肯定不在话下，现在是给你一个按钮，直接点击下PDF，以后可能通过整合Web of Science，比如给你期刊的影响因子、学科排名等Clarivate Analytics的拳头产品。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>爆炸型的饼图</title>
      <link>https://guangchuangyu.github.io/2018/05/explode-pieplot/</link>
      <pubDate>Tue, 15 May 2018 23:44:55 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/05/explode-pieplot/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/zhishixingqiu/pie_question.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;这是CJ在我的星球里分享的一个关于饼图的实现方式，代码的排版太差，还有一点是对于普通用户来说，还是有点难度，如果是我，必须是写成函数，直接出图。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggplot2新参数clip</title>
      <link>https://guangchuangyu.github.io/2018/05/ggplot2-clip/</link>
      <pubDate>Fri, 04 May 2018 13:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/05/ggplot2-clip/</guid>
      <description>&lt;p&gt;《&lt;a href=&#34;http://mp.weixin.qq.com/s/BTBP_snTRKrjmRCjF6Cp3A&#34;&gt;ggplot2字体溢出的那点破事&lt;/a&gt;》这是经典老问题了，现在新版本的&lt;code&gt;ggplot2&lt;/code&gt;有新的解决方案了，在&lt;code&gt;coord_cartesian&lt;/code&gt;中新加入了&lt;code&gt;clip&lt;/code&gt;参数，这样可以支持把图层画在画布之外，那么文本打过界也就支持了。这有一个好处，是可以支持direct label，而不需要调整&lt;code&gt;xlim&lt;/code&gt;和&lt;code&gt;ylim&lt;/code&gt;，毕竟你把&lt;code&gt;xlim&lt;/code&gt;和&lt;code&gt;ylim&lt;/code&gt;搞大有时候会给人以误导，认为你的数据取值范围就是图中的&lt;code&gt;xlim&lt;/code&gt;和&lt;code&gt;ylim&lt;/code&gt;，但实际上要小一些。&lt;/p&gt;
&lt;p&gt;我以&lt;code&gt;ggtree&lt;/code&gt;为例，为了让tip label打全，那么&lt;code&gt;p1&lt;/code&gt;把时间给搞到2020，但实际上最近的采样时间是2013年，这样你单看&lt;code&gt;x&lt;/code&gt;轴的标记，总感觉有一点点不对路，或者有一点点别扭。现在好了，我不设置&lt;code&gt;xlim&lt;/code&gt;，而是让label打过界，当然还是需要有足够的空间来放这些文本，这个可以通过把&lt;code&gt;margin&lt;/code&gt;搞大来实现。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>R-3.5.0发布，又该升级了</title>
      <link>https://guangchuangyu.github.io/2018/04/r-35-release/</link>
      <pubDate>Wed, 25 Apr 2018 17:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/04/r-35-release/</guid>
      <description>&lt;p&gt;R &lt;code&gt;3.5.0&lt;/code&gt;已经发布了，我昨天已经更新了，Bioconductor也将在5月初发布&lt;code&gt;3.7&lt;/code&gt;版本，就我个人而言，新版的Bioconductor主要有以下一些新东西：&lt;/p&gt;
&lt;h2 id=&#34;enrichplot&#34;&gt;enrichplot&lt;/h2&gt;
&lt;p&gt;新包&lt;code&gt;enrichplot&lt;/code&gt;，《&lt;a href=&#34;https://mp.weixin.qq.com/s/93XIeDF3mUFX0koX6mTRpA&#34;&gt;enrichplot: 让你们对clusterProfiler系列包无法自拔&lt;/a&gt;
》，以后&lt;code&gt;clusterProfiler&lt;/code&gt;系列出图更好看了，而且所有图你都可以用&lt;code&gt;cowplot&lt;/code&gt;拼图。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>用ggplot2画维恩图</title>
      <link>https://guangchuangyu.github.io/2018/04/ggvenn/</link>
      <pubDate>Mon, 23 Apr 2018 19:00:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/04/ggvenn/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/zhishixingqiu/ggvenn_question.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;这是去年「知识星球」里的提问，「知识星球」相当于是众筹我一年的时间，向我提问，请谨慎入坑。&lt;/p&gt;
&lt;p&gt;我当时就写了一个函数&lt;code&gt;ggvenn&lt;/code&gt;，这个函数其实包装了&lt;code&gt;venneuler&lt;/code&gt;，但由于&lt;code&gt;venneuler&lt;/code&gt;依赖&lt;code&gt;rJava&lt;/code&gt;，而很多小伙伴不会装&lt;code&gt;rJava&lt;/code&gt;，而因此装不了&lt;code&gt;yyplot&lt;/code&gt;，所以我去掉了这个依赖，但如果你想要用&lt;code&gt;ggvenn&lt;/code&gt;这个函数，请自行安装&lt;code&gt;rJava&lt;/code&gt;和&lt;code&gt;venneuler&lt;/code&gt;。其实还有另外一个包，&lt;code&gt;VennDiagram&lt;/code&gt;，它的输出是&lt;code&gt;gList&lt;/code&gt;，所以可以直接封装为&lt;code&gt;ggplot2&lt;/code&gt;图层，然而对于画venn plot，我并没有太多的兴趣，《&lt;a href=&#34;http://mp.weixin.qq.com/s/MqpfgkMJSFj0pYwcEjV9kQ&#34;&gt;CS6: ChIPseeker的可视化方法（中秋节的视觉饕餮）&lt;/a&gt;》一文中介绍的upset plot，可能更好一些。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>rename phylogeny tip labels in treeio</title>
      <link>https://guangchuangyu.github.io/2018/04/rename-phylogeny-tip-labels-in-treeio/</link>
      <pubDate>Thu, 19 Apr 2018 11:00:08 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/04/rename-phylogeny-tip-labels-in-treeio/</guid>
      <description>
&lt;script src=&#34;https://guangchuangyu.github.io/rmarkdown-libs/header-attrs/header-attrs.js&#34;&gt;&lt;/script&gt;


&lt;p&gt;I don’t know whether ‘rename taxa’ is a common task or not. It seems not a good idea to rename taxa in Newick tree text, since it may introduce problems when mapping the original sequence alignment to the tree.&lt;/p&gt;
&lt;p&gt;If you just want to show different or additional information when plotting the tree, it is fine and easy to do it using &lt;code&gt;ggtree&lt;/code&gt;:&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>setting ggplot2 background with ggbackground</title>
      <link>https://guangchuangyu.github.io/2018/04/setting-ggplot2-background-with-ggbackground/</link>
      <pubDate>Wed, 18 Apr 2018 21:00:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/04/setting-ggplot2-background-with-ggbackground/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://cran.r-project.org/package=ggimage&#34;&gt;ggimage&lt;/a&gt; 0.1.4 is available on CRAN.&lt;/p&gt;
&lt;p&gt;This release introduces a new function called &lt;code&gt;ggbackground&lt;/code&gt; for setting image background as &lt;code&gt;ggplot&lt;/code&gt; canvas.&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code class=&#34;language-{r&#34; data-lang=&#34;{r&#34;&gt;require(magick)
require(ggplot2)
require(ggimage) 
&lt;/code&gt;&lt;/pre&gt;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code class=&#34;language-{r}&#34; data-lang=&#34;{r}&#34;&gt;require(ggplot2)
p &amp;lt;- ggplot(iris) + aes(x = Sepal.Length, y = Sepal.Width, color=Species) + 
    geom_point(size=5) + theme_classic()
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Suppose we have the above &lt;code&gt;ggplot&lt;/code&gt; object, &lt;code&gt;p&lt;/code&gt;, the only thing we need to do is passing the &lt;code&gt;p&lt;/code&gt; with an image file name (local or remote) to &lt;code&gt;ggbackground&lt;/code&gt;, as demonstrated below:&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>使用ggbackground设置ggplot2的背景</title>
      <link>https://guangchuangyu.github.io/2018/04/ggbackground/</link>
      <pubDate>Wed, 18 Apr 2018 21:00:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/04/ggbackground/</guid>
      <description>&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;require(ggplot2)
 p &amp;lt;- ggplot(iris) + aes(x = Sepal.Length, y = Sepal.Width, color=Species) + 
    geom_point(size=5) + theme_classic()
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;首先我们有一个图，是用&lt;code&gt;ggplot2&lt;/code&gt;画的，上面这图大家太熟悉，不打印出来都知道是什么了。&lt;/p&gt;
&lt;p&gt;我在最新版的&lt;code&gt;ggimage&lt;/code&gt;中加入了一个&lt;code&gt;ggbackground&lt;/code&gt;的函数，我随便从网上找一张&lt;code&gt;iris&lt;/code&gt;的图片，我们把&lt;code&gt;p&lt;/code&gt;和&lt;code&gt;img&lt;/code&gt;同时传给&lt;code&gt;ggbackground&lt;/code&gt;就好了，非常容易，于是图的内容还是一样，但加了一张我们给定的图片做为背景。&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;require(ggimage) 
img = &amp;quot;https://assets.bakker.com/ProductPics/560x676/10028-00-BAKI_20170109094316.jpg&amp;quot;
ggbackground(p, img)
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>滚吧，骚年</title>
      <link>https://guangchuangyu.github.io/2018/04/get-away/</link>
      <pubDate>Mon, 09 Apr 2018 18:30:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/04/get-away/</guid>
      <description>&lt;p&gt;4月3号发了以下一条文字推送：&lt;/p&gt;
&lt;p&gt;遇到辣鸡导师，只有三个字，忍滚狠，我选择滚，考博期间，发现人品不好，我选择滚，《&lt;a href=&#34;https://mp.weixin.qq.com/s/LzwSAYT7yyYTMrNnck9KCg&#34;&gt;来香港读博其实是被逼的&lt;/a&gt;》，读博期间，本着就是退学也要滚的心态，把导师给炒了，《&lt;a href=&#34;http://mp.weixin.qq.com/s/iRC_ak53PbN9DJbkPzgBOQ&#34;&gt;CS10: 八卦终结版&lt;/a&gt;》，忍下来也会消磨掉你所有追求/理想，比狠的话，如果没有压制对方的渠道，对于这种势力严重不均衡的情况似乎不太现实，所以我奉劝大家，滚！一两年的沉没时间，放长远了看，根本不算什么，要勇于放弃，滚的远远的&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>dotplot支持使用formula指定x轴变量</title>
      <link>https://guangchuangyu.github.io/2018/04/dotplot-x-axis/</link>
      <pubDate>Sun, 08 Apr 2018 19:06:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/04/dotplot-x-axis/</guid>
      <description>&lt;p&gt;使用&lt;code&gt;barplot&lt;/code&gt;来展示富集分析结果是很常用的，而&lt;code&gt;dotplot&lt;/code&gt;比较&lt;code&gt;barplot&lt;/code&gt;来说，多了一个点大小的信息，可以比&lt;code&gt;barplot&lt;/code&gt;展示多一个信息，所以是比较推荐的，我之前已经写了《&lt;a href=&#34;https://mp.weixin.qq.com/s/KzcnIH88d4E41Ybvr_76zA&#34;&gt;dotplot展示富集分析结果&lt;/a&gt;》和《&lt;a href=&#34;https://mp.weixin.qq.com/s/JLon7oaddmTpsMzL03OJIA&#34;&gt;dotplot for GSEA&lt;/a&gt;》两篇文章，&lt;code&gt;dotplot&lt;/code&gt;虽然简单，很多人会觉得会容易用&lt;code&gt;ggplot2&lt;/code&gt;画出来，但其实有些细节，比如《&lt;a href=&#34;https://mp.weixin.qq.com/s/VW4LvtQqXumrs6SMvwGgvQ&#34;&gt;为什么画出来的点比指定的数目要多？&lt;/a&gt;》，有些技巧，比如《&lt;a href=&#34;https://mp.weixin.qq.com/s/JNIncz3W-59yjGk2ibJWUw&#34;&gt;搞大你的点，让我们画真正的气泡图&lt;/a&gt;》，是很多新手所不具备的，图虽然简单，但老司机的飚车技能也不可小看哦，所以我在《&lt;a href=&#34;https://mp.weixin.qq.com/s/bloMPypAkQ3Ovlh406M-FQ&#34;&gt;听说你也在画dotplot，但是我不服！&lt;/a&gt;》的文后就说了一句话：&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;clusterProfiler之所以好，因为真的考虑了很多细节！请放开那图，让clusterProfiler来画！&lt;/p&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>在VSCode中愉快地使用R</title>
      <link>https://guangchuangyu.github.io/2018/04/vscode-r/</link>
      <pubDate>Tue, 03 Apr 2018 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/04/vscode-r/</guid>
      <description>&lt;p&gt;在《&lt;a href=&#34;http://mp.weixin.qq.com/s/BsEm76Eq9_tbw3myobD_SA&#34;&gt;你所不知道的，R的N种打开方式&lt;/a&gt;》我介绍了N多种打开R的方式，甚至于你还能用python写的号称21世纪的R界面：《&lt;a href=&#34;https://mp.weixin.qq.com/s/VbMq3ZKMdn0E3wauC4l_hg&#34;&gt;R，python喊你回家吃饭啦&lt;/a&gt;》。&lt;/p&gt;
&lt;p&gt;我自己一直很少用RStudio，而是用Emacs，虽然Emacs比较小众，也不适合这个公众号的粉丝，但文本编辑器之于程序程好比剑客手中的剑，一个用着顺手、长期使用的文本编辑器比什么都好，在《&lt;a href=&#34;http://mp.weixin.qq.com/s/BsEm76Eq9_tbw3myobD_SA&#34;&gt;你所不知道的，R的N种打开方式&lt;/a&gt;》中我介绍了Emacs, Vim, textMate, sublime，今天要介绍另一款，VSCode，这是微软开源的文本编辑器，非常现代化，有很好的扩展生态。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>怎样用HOMER算出的P-value画出CNS级别的泡泡图？</title>
      <link>https://guangchuangyu.github.io/2018/03/dotplot-for-homer-motif/</link>
      <pubDate>Thu, 29 Mar 2018 11:23:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/03/dotplot-for-homer-motif/</guid>
      <description>&lt;ul&gt;
&lt;li&gt;第一棒：&lt;a href=&#34;http://mp.weixin.qq.com/s/pTzvbfk5Ohu45RXb-ePzHw&#34;&gt;CNS里的泡泡图&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;第二棒：&lt;a href=&#34;http://mp.weixin.qq.com/s/PVHCiqhzoW3DsvdsVQIKJg&#34;&gt;怎样用HOMER找motif？&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;第三棒：怎样用HOMER算出的P-value画出CNS级别的泡泡图？&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;这是小伙伴的命题作文，下面这个数据是曾老湿给出来的，其中header行竟然放在了最后一行，我手工把它挪到了第一行，里面还有一个数据缺失的，会导致读了数据后会有NA值，需要去除。&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/MISC/motif_dotplot_data.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;$ file summary_ATAC_seq_motif.xlsx                                                                                     
summary_ATAC_seq_motif.xlsx: Microsoft Excel 2007+
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;这是一个Excel文件，我们可以用&lt;code&gt;readxl&lt;/code&gt;来读：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;require(readxl)
x &amp;lt;- read_xlsx(&amp;quot;summary_ATAC_seq_motif.xlsx&amp;quot;)
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>用散点可视化一个矩阵</title>
      <link>https://guangchuangyu.github.io/2018/03/scatterplot-for-matrix/</link>
      <pubDate>Mon, 26 Mar 2018 14:33:50 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/03/scatterplot-for-matrix/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/Bioconductor/ggtree/align_tree_pairwise_dist_files/WechatIMG601.jpeg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;当然是ggplot2画，才好和ggtree兼容，你首先问自己，抛开树，你能右边吗？本身你有个矩阵，row的顺序要跟着树来，你可以先不管，先随意，这是y轴。那x轴呢？你矩阵里的数字，打点你总该会的，而点连线，同样column的数字打出来的点，就连在一起，你先按这个思路画出来，再来问后续的。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;这是我在「知识星球」中的回答，然而小伙伴表示还是不懂。那么我来详细讲解一下：&lt;/p&gt;
&lt;p&gt;首先我们读入一个FASTA数据：&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;require(treeio)

fasta &amp;lt;- system.file(&amp;quot;examples/FluA_H3_AA.fas&amp;quot;, package=&amp;quot;ggtree&amp;quot;)
aa &amp;lt;- read.fasta(fasta)
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;数据用&lt;code&gt;treeio&lt;/code&gt;包里的&lt;code&gt;read.fasta&lt;/code&gt;去读这个氨基酸序列，它有个好处是你直接&lt;code&gt;as.character(aa[[i]])&lt;/code&gt;就是个字母的向量，方便比较。&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;n = length(aa)
d = matrix(NA, ncol=n, nrow=n)
nm = labels(aa)
rownames(d) = colnames(d) = nm

for (i in seq_len(n)) {
    for (j in seq_len(i)) {
        d[i, j] = mean(as.character(aa[[i]]) != as.character(aa[[j]]))
        d[j, i] = d[i, j]
    }
} 
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;这段代码生成了pairwise distance矩阵，你可以搞其它的统计量，都OK的。大家可以想一想，一般这种矩阵怎么可视化？用热图！热图用数字来填充颜色，而现在我们把数字当成x轴上的变量，然后打点，仅此而已，我们有没有办法画出来，当然可以。同样row的数值会在同一y轴上，如果是热图，同一column的数值会在同一x轴上，方便横向和纵向比较，而现在同一column的数值不在同一直线一了，因为我们打的点的位置使用了矩阵中的数值，同一column的点被拉扯到不同的位置上去了，所以为了能够比较或者是看清楚同一column上的点的走势，我们把同一column上的点用线条连接在一起。这就是小伙伴提问的图，就是这么画出来的，非常简单。我在「知识星球」里其实已经解答得很清楚了。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>R给你的数据化了妆？</title>
      <link>https://guangchuangyu.github.io/2018/03/colnames-of-data-frame/</link>
      <pubDate>Mon, 26 Mar 2018 09:33:50 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/03/colnames-of-data-frame/</guid>
      <description>&lt;p&gt;小伙伴说他写个CSV文件，名字就变了，无缘无故&lt;code&gt;|&lt;/code&gt;就被改了，还有些名字被强加了&lt;code&gt;X&lt;/code&gt;。我注意到了他写的对象是&lt;code&gt;data.frame(d)&lt;/code&gt;，这锅绝对是&lt;code&gt;data.frame&lt;/code&gt;的。&lt;/p&gt;
&lt;p&gt;我们可以试一下：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;&amp;gt; d = matrix(rnorm(4), ncol=2)
&amp;gt; colnames(d) = c(&amp;quot;A|B&amp;quot;, &amp;quot;123&amp;quot;)
&amp;gt; write.csv(data.frame(d))
&amp;quot;&amp;quot;,&amp;quot;A.B&amp;quot;,&amp;quot;X123&amp;quot;
&amp;quot;1&amp;quot;,-0.601247669017546,0.802654193340092
&amp;quot;2&amp;quot;,-0.128752028398414,0.430829592244036
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&lt;strong&gt;没错，自己给变了。&lt;/strong&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>画图给点分组?</title>
      <link>https://guangchuangyu.github.io/2018/03/group-points/</link>
      <pubDate>Tue, 20 Mar 2018 12:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/03/group-points/</guid>
      <description>&lt;p&gt;小伙伴提出了上面的问题，点不能够打到violin里面去，即使加了&lt;code&gt;aes(group=color)&lt;/code&gt;强行分组也不行。这个照理第一感觉都会觉得可以，但试一下都会发现不行。&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;library(ggplot2)
d = subset(diamonds, color %in% c(&amp;quot;D&amp;quot;, &amp;quot;E&amp;quot;))
ggplot(d, aes(cut, carat, fill=color, color=color)) + 
    geom_violin(alpha=.3) + geom_jitter(width=.05, alpha=.5)
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/R/ggplot2/group_point/unnamed-chunk-1-1.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>一条指令把统计&#43;画图都给做了？似乎太美好！</title>
      <link>https://guangchuangyu.github.io/2018/03/ggstatsplot/</link>
      <pubDate>Fri, 16 Mar 2018 09:09:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/03/ggstatsplot/</guid>
      <description>&lt;p&gt;大家是否还记得我写的文章《&lt;a href=&#34;https://mp.weixin.qq.com/s/8kqTVSDjuHpivGaim6ukNg&#34;&gt;画个小圈圈&lt;/a&gt;》？里面吐槽了&lt;code&gt;ggpubr&lt;/code&gt;这个包的存在是&lt;strong&gt;制造混乱，徒增学习成本&lt;/strong&gt;。我们知道&lt;code&gt;ggplot2&lt;/code&gt;包里有个&lt;code&gt;qplot&lt;/code&gt;函数，而在《ggplot2》的第一版中，hadley先用了一章介绍&lt;code&gt;qplot&lt;/code&gt;，再介绍grammar of graphics，然后这个&lt;code&gt;qplot&lt;/code&gt;就被吐槽，先入为主，给学习grammar of graphics，学习ggplot2语法制造了不必要的麻烦。然后如果你看《ggplot2》第二版，你就会发现&lt;code&gt;qplot&lt;/code&gt;这一章被删掉了。我说&lt;code&gt;ggpubr&lt;/code&gt;&lt;strong&gt;制造混乱，徒增学习成本&lt;/strong&gt;并不是为了吐槽某公众号，而是实事求是。&lt;/p&gt;
&lt;p&gt;我并不反对封装，我并没有强迫症说大家一定要用ggplot2图形语法，而不能封装函数，我想我在《&lt;a href=&#34;https://mp.weixin.qq.com/s/8kqTVSDjuHpivGaim6ukNg&#34;&gt;画个小圈圈&lt;/a&gt;》已经说得很清楚了，封装画图的包，按我的观点是要么卖了数据处理的专业知识，要么卖了画图的专业知识。如果一个包做的封装太过于简单，像&lt;code&gt;ggpubr&lt;/code&gt;这种，数据必须是用户整理好的data.frame，而画图只是简单的两三个图层的叠加，那么当然可以减少你敲键盘输入，然而影响了初级用户学习&lt;code&gt;ggplot2&lt;/code&gt;，复杂的东西，我们当然想要用封装好的函数，等你自己啥都搞懂了，老板都要跟你掀桌子了。简单的东西也可以封装，减少输入嘛，只是特别不适用于ggplot2的图层，简单的设定你写个主题，我都举双手赞成，但两三个图层的简单拼凑我不支持，因为图层是积木，大家学习就是要对积木熟悉，然后才能搭出复杂的东西出来。特别简单的图层叠加正是你熟悉积木的时候，你不多敲点键盘，做为练习，又怎么能做出稍复杂点的东西呢？&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>扪心自问，meme几何？</title>
      <link>https://guangchuangyu.github.io/2018/03/five-questions-of-meme/</link>
      <pubDate>Tue, 13 Mar 2018 13:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/03/five-questions-of-meme/</guid>
      <description>&lt;p&gt;很多人都在学&lt;code&gt;ggplot2&lt;/code&gt;，也有很多「高手」，比如你搜索「精通ggplot2」，你甚至会看到各种「从入门到精通」的课程，然而都是各种照猫画老虎的入门菜谱而已，当然广大群众去上课也可能只是为了求菜谱好在需要的时候，可以copy-paste而已。&lt;/p&gt;
&lt;p&gt;&lt;code&gt;ggplot2&lt;/code&gt;学习容易，因为无非是图层叠加，而图层的参数一致性非常好，网上也有很全的文档。然而要深入很难，比如你想干点什么是&lt;code&gt;ggplot2&lt;/code&gt;自身没有支持的，你需要自己去hack，需要用到更底层的东西的时候，一般情况下，会无从入手，尝试之后才知道什么叫绝望！因为&lt;code&gt;ggplot2&lt;/code&gt;套路实在是太深。&lt;/p&gt;
&lt;p&gt;正如我在《&lt;a href=&#34;http://mp.weixin.qq.com/s/Xhi_ZkrEzUVdnCu7ECBS4w&#34;&gt;听说你还不会画热图&lt;/a&gt;》吐槽的，有些所谓的「高手」实际上连&lt;code&gt;ggplot2&lt;/code&gt;底层是什么都不知道！然后可以把&lt;code&gt;ggplot2&lt;/code&gt;吹上天。很多人根本不知道当你打下&lt;code&gt;ggplot&lt;/code&gt;这个命令的时候，到底发生了什么？要理解&lt;code&gt;ggplot2&lt;/code&gt;并不容易，正如前面所说「套路太深」，没有金钢钻，读不了它的代码，有没有一个简单点的包，能够读懂代码，并且有助于理解&lt;code&gt;ggplot2&lt;/code&gt;呢？我想我的&lt;code&gt;meme&lt;/code&gt;包就非常好，虽然仿的有点肤浅，然而胜在简单，看过下面这两篇文章的，都知道这个包在做什么。&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;http://mp.weixin.qq.com/s/jDXjkrkq_YVhW-Z5Vx2-Fg&#34;&gt;用R画meme ;)&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s/4b8enFCd_lLt278Ddxp3rg&#34;&gt;使用外部字体画meme&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;</description>
    </item>
    
    <item>
      <title>add treescale to unrooted tree</title>
      <link>https://guangchuangyu.github.io/2018/03/treescale_unrooted_tree/</link>
      <pubDate>Mon, 05 Mar 2018 13:17:48 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/03/treescale_unrooted_tree/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;I am trying to add a scale to an unrooted tree with &lt;code&gt;geom_treescale&lt;/code&gt;, but when I use it, the tree completely collapses and I am not able to set anything that fix it. Anybody has any idea on how to do it ?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;a href=&#34;https://groups.google.com/d/msgid/bioc-ggtree/9d69f444-94cf-42df-8382-bca2962b08c9%40googlegroups.com&#34;&gt;google group&lt;/a&gt;里的问题，说他加&lt;code&gt;geom_treescale&lt;/code&gt;之后，树被压缩了，由于他没有给出可重复性的例子，所以我们并不知道情况到底有多么糟糕，但这种情况是可能发生的，因为加&lt;strong&gt;treescale&lt;/strong&gt;这种东西，默认情况下&lt;code&gt;geom_treescale&lt;/code&gt;会自己去计算该加多大的scale bar，该放在什么位置上，而这种默认情况是基于rectangular布局来的，在假设的情况下，都不可能尽善尽美，假设不成立的情况下当然有可能搞得很差。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>用par设置ggplot2参数？这个可以有！</title>
      <link>https://guangchuangyu.github.io/2018/03/ggpar/</link>
      <pubDate>Thu, 01 Mar 2018 10:17:48 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/03/ggpar/</guid>
      <description>&lt;p&gt;有小伙伴在说可以用par(mar)来设置画图的margin，但不能应用于ggplot2，这个可能很多新手都会很困扰，可能需要一段时间的探索之后，才能发现原来是用theme来设定。&lt;/p&gt;
&lt;p&gt;这当然你可以归结于说ggplot2和base plot是不同的东西，但从实质画图参数这一点而言，并没有什么同与不同，无非是设置的方式不同而已，而这种方式都是人定义的，我们完全可以人为定义它们兼容。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>elementary-美观而易用的Linux发行版</title>
      <link>https://guangchuangyu.github.io/2018/02/elementaryos/</link>
      <pubDate>Sat, 24 Feb 2018 04:33:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/02/elementaryos/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2018/linux_win.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;想当年还在读本科那会，debian还是比较阳春的东西，然后就被ubuntu给普及了，ubuntu我实际上是不喜欢的，如果有linux的问题，搜出来是ubuntu的链接，我基本不会点开，ubuntu用的人实在太多，而且是特别多的小白，真正好的发行版是gentoo和arch，文档齐全，小白少。我目前使用的就是arch，因为gentoo实在是笔记本吃不消天天在编译。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>改变outgroup的枝长</title>
      <link>https://guangchuangyu.github.io/2018/02/changing-branch-length-of-outgroup/</link>
      <pubDate>Fri, 23 Feb 2018 18:23:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/02/changing-branch-length-of-outgroup/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Hello all,&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;When I plot some data using ggtree, the out groups are on a very long branch length. The out groups are 75 and 76 in the example below.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;I would like to keep the out groups in the tree but ignore their branch lengths to make presentation easier.&lt;/p&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>秒杀一切手工画通路的素材</title>
      <link>https://guangchuangyu.github.io/2018/02/reactome-icon/</link>
      <pubDate>Sun, 11 Feb 2018 02:22:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/02/reactome-icon/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2018/reactome-icon/path.gif&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;像这样的通路图，基本上都是手工画的，也有几个软件可以做这事，但都不流行，毕竟也没啥，无非是素材，所以多半还是素材+熟悉的软件，比如有illustrator、fireworks以及最受欢迎的powerpoint。像illustrator很多人已经很熟，或者powerpoint绝对够傻瓜操作，我们需要的只是素材，自制素材也是可以的，但费时且有时候还不够好看。很多人还在费力收集网上可以下载到的各种素材，很多素材覆盖面不够广，而不同来源的素材混搭有时候会有种画风不对的感觉。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>一千个伤心的理由</title>
      <link>https://guangchuangyu.github.io/2018/02/broken-heart/</link>
      <pubDate>Thu, 08 Feb 2018 00:21:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/02/broken-heart/</guid>
      <description>&lt;p&gt;眼看着2月14号就要到来了，又是一年一度的画红心装13的时候，这种事情已经被我BS了，请猛击：《&lt;a href=&#34;http://mp.weixin.qq.com/s/Y8IHd6X4f49irXvD_M7bNw&#34;&gt;画❤️装geek什么的，都弱爆了！😜&lt;/a&gt;》。红心已经没什么好画的了，特别是在我画了生日蛋糕，并用蛋糕画红心之后，《&lt;a href=&#34;https://mp.weixin.qq.com/s/Iqcqo5YTy1qmXdsuIrlrYQ&#34;&gt;130岁了，祝你生快&lt;/a&gt;》，是驴子是马，都没法晒肌肉了。当然红心还是会有所谓的理工宅男晒，除此之外还会有各种花招，来给单身狗撒狗粮。想要加入撒狗粮大军的，快点看《&lt;a href=&#34;http://mp.weixin.qq.com/s/2j9VRgar5ExSma6B7Yc3dw&#34;&gt;如何告别单身&lt;/a&gt;》。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Y叔要求职</title>
      <link>https://guangchuangyu.github.io/2018/02/job-wanted/</link>
      <pubDate>Wed, 07 Feb 2018 13:30:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/02/job-wanted/</guid>
      <description>&lt;p&gt;余光创
香港大学 生物信息学 博士，目前在港大从事博士后工作
求职意向：副教授以上
地点：主要意向是广州和深圳&lt;/p&gt;
&lt;p&gt;简历：&lt;a href=&#34;https://guangchuangyu.github.io/resume/YGC.pdf&#34;&gt;https://guangchuangyu.github.io/resume/YGC.pdf&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;google scholar指标：&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;引用：1330&lt;/li&gt;
&lt;li&gt;h-index: 14&lt;/li&gt;
&lt;li&gt;i10-index: 17&lt;/li&gt;
&lt;/ul&gt;</description>
    </item>
    
    <item>
      <title>网瘾你好，我是80后，请冲我来</title>
      <link>https://guangchuangyu.github.io/2018/02/wechat-addition/</link>
      <pubDate>Mon, 05 Feb 2018 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/02/wechat-addition/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/2018/wechat_additive/images.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;童鞋们，敲黑板划重点啦，上图请对号入坐，没错，说的就是你！这个网瘾的骚年！&lt;/p&gt;
&lt;p&gt;Scientific Report最近发表了&lt;a href=&#34;https://www.nature.com/articles/s41598-018-19904-y&#34;&gt;一篇神文&lt;/a&gt;:&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>关于scihub，一文就够了</title>
      <link>https://guangchuangyu.github.io/2018/01/scihub-bookmark/</link>
      <pubDate>Mon, 29 Jan 2018 07:05:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/01/scihub-bookmark/</guid>
      <description>&lt;p&gt;Sci-Hub是居家旅行学术必备的神器，毕竟穷人比较多，而出版社太黑心。但Sci-Hub有一个问题是镜像站经常挂，我之前给出了一个比较可能不会挂的链接，《&lt;a href=&#34;https://mp.weixin.qq.com/s/5JGC1bcVZOmdaPxo_uXYYw&#34;&gt;再不用担心打不开sci-hub了&lt;/a&gt;》，那就是洋葱链接。当然洋葱链接比较慢，我们还是更倾向于使用普通的链接，所以我又收集了《&lt;a href=&#34;https://mp.weixin.qq.com/s/RK1CYEboiEDzapdHsiwEGg&#34;&gt;2018最新可用的sci-hub镜像+桌面版程序&lt;/a&gt;》，当然这些链接随着时间的推移，有些可能也会挂。&lt;/p&gt;
&lt;p&gt;任何时候，我们都应该有多手准备，所以我一直都有备选方案，虽然不如sci-hub，虽然现在sci-hub还能用的情况下首先还是sci-hub，但收藏一两个备选工具是必要的，它让你在面前变化的时候可以淡定。《&lt;a href=&#34;http://mp.weixin.qq.com/s/aaIby87LSQgxpvCAECFxkw&#34;&gt;sci-hub如果挂了，你还有神器下文献吗？&lt;/a&gt;》这篇文章介绍的神器即使你现在不用，也该收藏着。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Y叔不想养蛙，只想养你！</title>
      <link>https://guangchuangyu.github.io/2018/01/frog-tree/</link>
      <pubDate>Thu, 25 Jan 2018 20:03:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/01/frog-tree/</guid>
      <description>&lt;p&gt;话说有一只蛙，它旅游去了广东，游戏结束。&lt;/p&gt;
&lt;p&gt;这篇文章，只想跟大家讲一讲ggtree，你值得拥有的强大的进化树可视化软件，高颜值的图，就在于指尖几行代码中。&lt;/p&gt;
&lt;p&gt;最近养蛙很流行，就以蛙为例，读树用&lt;code&gt;read.tree&lt;/code&gt;，然后一个&lt;code&gt;ggtree&lt;/code&gt;的指令，树就画出来了。而你见证神奇的时刻就在于你不断&lt;code&gt;+geom_xxx&lt;/code&gt;加图层，这里我用了&lt;code&gt;geom_tiplab&lt;/code&gt;来加taxa label，而这个可不仅仅是名字哦，用emoji也可以，这里我用的竟然是&lt;strong&gt;图片&lt;/strong&gt;，你没看错，也可以。只要指定&lt;code&gt;geom=&amp;quot;image&amp;quot;&lt;/code&gt;就OK，那个本来要打的文本，就会被当成是文件名，然后读图片画图片，一切尽在我的ggimage包。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>苹果版SciHub桌面软件</title>
      <link>https://guangchuangyu.github.io/2018/01/scihub-osx/</link>
      <pubDate>Wed, 24 Jan 2018 15:27:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/01/scihub-osx/</guid>
      <description>&lt;p&gt;为了方便苹果用户也能用桌面软件下文献，我把SciHub桌面版打包成可以运行在苹果上的App。&lt;/p&gt;
&lt;p&gt;SciHub桌面版是Windows程序，主页为&lt;a href=&#34;https://zhuanlan.zhihu.com/p/31809890&#34;&gt;https://zhuanlan.zhihu.com/p/31809890&lt;/a&gt;。&lt;/p&gt;
&lt;p&gt;首先这是利用wine技术实现的，在苹果上你需要安装&lt;strong&gt;XQuartz&lt;/strong&gt;: &lt;a href=&#34;https://www.xquartz.org/&#34;&gt;https://www.xquartz.org/&lt;/a&gt;。&lt;/p&gt;
&lt;p&gt;安装很容易，我已经打包了dmg文件，这个文件有44M，还挺大的，没法，要打包一个windows的运行环境嘛。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>PubMed没有停更</title>
      <link>https://guangchuangyu.github.io/2018/01/pubmed-still-update/</link>
      <pubDate>Mon, 22 Jan 2018 14:33:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/01/pubmed-still-update/</guid>
      <description>&lt;p&gt;在一篇文章《&lt;a href=&#34;http://mp.weixin.qq.com/s/VfLmahpFqdmXfwId-d_BWQ&#34;&gt;pubmed停更？和你没半毛钱关系！你们是想放假想疯了吧？&lt;/a&gt;》我就解读了所谓的停更，根本不碍事，然后又分析了事情只是被自媒体拿来博眼球而已，真正受影响的NCBI数据库没人说，而PubMed停更的可能性不大。&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Because of a lapse in government funding, the information on this website may not be up to date, transactions submitted via the website may not be processed, and the agency may not be able to respond to inquiries until appropriations are enacted.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;这个消息，很多人上pubmed看到，就打鸡血了，哟哟哟，号外号外大新闻，真的有过过脑子吗？&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;transactions submitted via the website may not be processed&lt;/p&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>ggplot2的一个坑</title>
      <link>https://guangchuangyu.github.io/2018/01/ggplot2-seed/</link>
      <pubDate>Mon, 22 Jan 2018 07:23:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/01/ggplot2-seed/</guid>
      <description>&lt;p&gt;今天以ggplot2的一个坑来说一下，坑无处不在，防不胜防，你大可以试一下下面的代码：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;&amp;gt; set.seed(123)
&amp;gt; require(ggplot2)
Loading required package: ggplot2
&amp;gt; rnorm(3)
[1]  0.8005543  1.1902066 -1.6895557
&amp;gt; set.seed(123)
&amp;gt; rnorm(3)
[1] -0.5604756 -0.2301775  1.5587083
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;在两次set.seed和rnorm之间，第一次因为加载了ggplot2，结果就不一样了！这必须是第二次是正确答案，也就是说加载ggplot2把你的seed给吃了！加载包会改变R环境？这绝对不是好主意，我们来试试加载别的包试试，比如我的clusterProfiler:&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>PubMed停更？</title>
      <link>https://guangchuangyu.github.io/2018/01/pubmed-stop-update/</link>
      <pubDate>Sun, 21 Jan 2018 23:23:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/01/pubmed-stop-update/</guid>
      <description>&lt;p&gt;今天学术圈刷屏的是美国政府关门，pubmed停更，有些标题党说成了美国政府破产，又说得好像中国人的科研也要跟着放假似的，还一堆人疯传，似乎暗示着pubmed也关门，而且没有pubmed会死一样。所以我感觉有必要普及一下姿势，毕竟吃瓜的人群基数太大。&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Holy shit what a fucking disaster, pubmed is such an amazing resource, unbelievable the US would let it waste away. What an embarrassment of a country.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;气愤归气愤，但标题党甚至于跑偏了就不可取了。无非只是停更，也就是说文章该发的照样发，只是暂时不会被收录进pubmed而已，也就是说pubmed照常用，只不过搜不到最新的文献，如果说这样就可以去放大假了，那么似乎如果不停更，你看多了几篇新文献，就能够发paper，迎娶白富美了？而看少了这最新的文献，就秒变科研屌丝，可以回家睡大觉了？&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;The website continues to work. The shutdown will be over in a few days and everything will go back to normal. You can also use Google Scholar, Web of Science, and Scopus.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;事实上，pubmed只是一个搜文献的数据库，它停更，文章照发，而大家可以通过别的途径去获得，如果你只有这一条途径，那么你做科研也确实少了点B数。上面提到的google scholar很多人可能上不去（&lt;a href=&#34;http://mp.weixin.qq.com/s/b6xyVv-HjQQSn0pq7ILQzw&#34;&gt;梯子在这里&lt;/a&gt;），而Scopus是要收费的。然后途径是很多的，&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>2018最新可用的sci-hub镜像&#43;桌面版程序</title>
      <link>https://guangchuangyu.github.io/2018/01/scihub/</link>
      <pubDate>Thu, 18 Jan 2018 07:05:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/01/scihub/</guid>
      <description>&lt;p&gt;之前的《&lt;a href=&#34;https://mp.weixin.qq.com/s/TMmsOsEn0wV9yXKOLma3Rw&#34;&gt;如何获取文献&lt;/a&gt;》介绍了方方面面，不单单是下载文献，而对于下载文献，scihub必须是首选，虽然我们有备选方案《&lt;a href=&#34;http://mp.weixin.qq.com/s/aaIby87LSQgxpvCAECFxkw&#34;&gt;sci-hub如果挂了，你还有神器下文献吗？&lt;/a&gt;》，但总是没scihub爽，之前介绍了用洋葱链接，《&lt;a href=&#34;https://mp.weixin.qq.com/s/5JGC1bcVZOmdaPxo_uXYYw&#34;&gt;再不用担心打不开sci-hub了&lt;/a&gt;
&lt;a href=&#34;https://mp.weixin.qq.com/s/AGQn7Lfn_nHHrtVQyJSTmg&#34;&gt;听说你也在读文献&lt;/a&gt;》，在写这篇文章的时候，我还测试了一下，现在依然可用！&lt;/p&gt;
&lt;p&gt;目前挂掉的scihub镜像已经很多，导致很多人认为scihub没法用了，其实还有很多的镜像是可以用的，当然能用的，以后也可能会挂，但新的镜像我相信还是会不断出现的，大家且行且珍惜吧。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>画一只恐龙</title>
      <link>https://guangchuangyu.github.io/2018/01/datasaurus/</link>
      <pubDate>Tue, 16 Jan 2018 17:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/01/datasaurus/</guid>
      <description>&lt;p&gt;大家是否还记得我的《&lt;a href=&#34;http://mp.weixin.qq.com/s/YuUOztQg3nUnhdvyg8asvg&#34;&gt;webinar录播 (2017-10-24)：plotting tree + data&lt;/a&gt;》，这可以说是R画图最好的课程，PPT也分享给大家《&lt;a href=&#34;https://mp.weixin.qq.com/s/3yEN-8oUck2WPmNQ368qYA&#34;&gt;ggtree直播PPT第一部分&lt;/a&gt;》和《&lt;a href=&#34;https://mp.weixin.qq.com/s/7-YhGzzu_tVAwySrYOKGFg&#34;&gt;ggtree直播PPT第二部分&lt;/a&gt;》。&lt;/p&gt;
&lt;p&gt;我在PPT中，用了meme，发现没有R包可以做，于是我写了一个R包来做这个事情。&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;http://mp.weixin.qq.com/s/jDXjkrkq_YVhW-Z5Vx2-Fg&#34;&gt;用R画meme ;)&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s/4b8enFCd_lLt278Ddxp3rg&#34;&gt;使用外部字体画meme&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://mp.weixin.qq.com/s/R5CxcdufLy6_yRPzOG4Baw&#34;&gt;花式打水印&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;后来又写一个R包来实现字体的阴影效果：&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;http://mp.weixin.qq.com/s/eZAmqeKBsbvAj9AvrTZRQQ&#34;&gt;带你装逼带你飞，画图的文本打出阴影立体效果 &lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;</description>
    </item>
    
    <item>
      <title>我被oncotarget撞了腰</title>
      <link>https://guangchuangyu.github.io/2018/01/oncotarget/</link>
      <pubDate>Sun, 14 Jan 2018 23:11:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/01/oncotarget/</guid>
      <description>&lt;p&gt;最近似乎就oncotarget是否要被SCI踢出来这事情，真真假假的报道挺多。以我的观点来看，它被踢是正常的；它不被踢也迟早要被踢！就像当年它的影响因子还在7点多的时候，我就预言oncotarget药丸一样，结果就直接掉到5点多，然后关于神刊的报道就开始多了起来。&lt;/p&gt;
&lt;p&gt;话说我在某高校工作的时候，有一个同事，他跳槽了！跳槽前各种暗渡陈仓，压着文章不发表，蓄谋已久的事情，然后就在跳槽的当年，可能为了掩饰，当年还继续招生，结果当然坑惨了那一届的学生，当然前面两三届也惨，因为数据压着不发表。&lt;/p&gt;
&lt;p&gt;虽然离职前和旧单位签了协议，数据是在旧单位做的，发表文章旧单位必须是通讯作者，仅此而已，反正都是他通讯，挂两单位而已嘛，这在学术界再正常不过。此人去了新单位之后，本来该发文章了，原来的学生干了几年，也该给人一个authorship了，然而他把新单位的领导放在了第一作者，自己当了通讯，原来的学生嘛，见鬼去了，其他作者多半是他的新同事/学生。当然通讯也没挂原单位，对于没有社会契约精神的人来说，协议就是一张废纸。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>使用新姿势玩KEGG</title>
      <link>https://guangchuangyu.github.io/2018/01/kegg-pathway-index/</link>
      <pubDate>Thu, 11 Jan 2018 15:21:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/01/kegg-pathway-index/</guid>
      <description>&lt;p&gt;有小伙伴说他要用gage这个包，因为可以选择sigmet这个index，然后得到的结果只有signaling and metabolic pathways，而不会有他不关心的disease pathways。然而也有各种不爽，他最喜欢的还是clusterProfiler，但没办法只做某些pathways。&lt;/p&gt;
&lt;p&gt;我发现大家对clusterProfiler有各种误解，各种觉得没办法，我也很无语啊，明明我写了大量的文档，你们偏不看。clusterProfiler啥都可以做，你想做COG，domain这些没有内置支持的富集分析都可以的，因为clusterProfiler是通用的分析工具，啥都能做。&lt;/p&gt;
&lt;p&gt;说到gage的pathway index，这其实是他们对pathway有个分类，这个数据就在&lt;a href=&#34;https://pathview.uncc.edu/data/khier.tsv&#34;&gt;https://pathview.uncc.edu/data/khier.tsv&lt;/a&gt;可以下载到，要支持他还不容易，但我不喜欢把别人的东西打包在自己的包里，所谓走别人的路，让别人无路可走，这可不是什么好主意。所以呢，我不会内置支持的，你们自己玩。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>画个小圈圈</title>
      <link>https://guangchuangyu.github.io/2018/01/geom-ord-ellipse/</link>
      <pubDate>Mon, 08 Jan 2018 13:13:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/01/geom-ord-ellipse/</guid>
      <description>&lt;p&gt;之前我发表读书笔记《&lt;a href=&#34;https://mp.weixin.qq.com/s/hPLlBAoN94TcyM-lP6jKCQ&#34;&gt;主成分分析&lt;/a&gt;》&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/2014/07/aa_pca.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;这可能是你见过最好看的PCA图了，有人在「宏基因组」群里问有没有什么包可以画？像这种提问，我以前是吐槽过的，请猛击《&lt;a href=&#34;https://mp.weixin.qq.com/s/4kJXBm7ojaTH6okLOFC7pA&#34;&gt;如何画类似MEME的注释序列&lt;/a&gt;》，当然说什么都没用，大家就是喜欢凡事问有包吗？因为包治百病嘛，不信你送个包给你女票试试！&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s/D2cuo5puCb_2GVA4Ae2QEA&#34;&gt;jimmy回答说ggbiplot&lt;/a&gt;可以画差不多的，于是「宏基因组」公众号立刻就出来一篇《&lt;a href=&#34;https://mp.weixin.qq.com/s/GGCPxQEe_DXefdp-veQtag&#34;&gt;ggbiplot-最好看的PCA作图：样品PCA散点+分组椭圆+变量贡献与相关&lt;/a&gt;》，后面又有人提问，能不能加两个置信区间？@Chenhao童鞋就给出了解决方案，并且写了篇&lt;a href=&#34;http://lchblogs.netlify.com/post/2017-12-22-r-addconfellipselda/&#34;&gt;博客文介绍&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;他的作图是基于&lt;code&gt;ggord&lt;/code&gt;包，只能应用于LDA，于是「宏基因组」公众号又跟进发一篇《&lt;a href=&#34;https://mp.weixin.qq.com/s/F9c_ISpOpjHyiCNahoYTqQ&#34;&gt;比PCA更好用的监督排序—LDA分析、作图及添加置信-ggord&lt;/a&gt;》，你会发现他们介绍同一类型的作图，一会这个包，一会那个包，一会某包有A功能，某包又有B功能，我就不说什么了。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>基因或蛋白之间，谁是谁的死党？</title>
      <link>https://guangchuangyu.github.io/2018/01/using-gosemsim-to-rank-proteins/</link>
      <pubDate>Tue, 02 Jan 2018 10:57:15 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2018/01/using-gosemsim-to-rank-proteins/</guid>
      <description>&lt;p&gt;很多人会有这样一个问题，差异基因一大堆，到底该选那个来做下游的实验验证？这个问题，说白了是个基因「重要性」的打分问题，你做差异基因分析的时候，就可以看做是个打分的过程，p值是你的统计量，p值越小，打分越高，然而所有的打分都是辅助帮我们进一步缩小范围而已，并不是打分越高就越「重要」，如果打分可以说明一切，那么我们就不需要实验验证了。所以像差异基因分析，我们一般是卡p &amp;lt; 0.01或p &amp;lt; 0.05来过滤，把p值小的基因留下来，但我们并不能说p值最小的基因就是最重要的。&lt;/p&gt;
&lt;p&gt;回到开头的问题，我们要的是对打分（差异分析）结果再利用别的手段，再一次进行打分，进一步缩小范围。比如你可以通过构建相互作用网络，通过分析betweenness，找hub分子。当然打分不一定是要基于基因/蛋白水平，也可以是通路水平，比如你可以用&lt;a href=&#34;http://mp.weixin.qq.com/s/ScwaofLd_ybfECYjL1dGow&#34;&gt;clusterProfiler进行富集分析&lt;/a&gt;，然后把你的目标限定在某个/些通路上。反正就是各种手段一起上，直到你能够限定到少量几个基因上，对于做实验验证的人来说，再好不过。&lt;/p&gt;
&lt;p&gt;上一周发表的《&lt;a href=&#34;https://mp.weixin.qq.com/s/FTzgf1JHXAhDta2u-cDksQ&#34;&gt;GOSemSim: GO语义相似性度量&lt;/a&gt;》，我记录了GOSemSim包被应用于各种各样的场景，它当然也可以拿来给基因/蛋白质打分。比如你用clusterProfiler分析后，就想验证某一通路，但不知道要选这个通路的哪个基因来做为切入点。&lt;/p&gt;
&lt;p&gt;首先问一个问题，同一通路上的基因功能相似性高吗？大家可能会潜意识地认为应该比较高，这不一定的，基因/蛋白有直接或间接的相互作用，但这种相互作用可能只是「月上柳梢头，人约黄昏后」而已，可能偶尔才来一发，这种属于约会型。一个基因/蛋白通常会参与到多条不同的通路中，如果两个蛋白在不同的通路中经常一起出现，那么它们的功能相似性才会高，这种属于基友/闺蜜的死党型。今天就来讲一讲到底谁和谁在约会，谁和谁又是死党。&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Y Han, &lt;strong&gt;G Yu&lt;/strong&gt;, H Sarioglu, A Caballero-Martinez, F Schlott, M Ueffing, H Haase, C Peschel, AM Krackhardt. &lt;a href=&#34;http://www.sciencedirect.com/science/article/pii/S1874391912007567&#34;&gt;Proteomic investigation of the interactome of FMNL1 in hematopoietic cells unveils a role in calcium-dependent membrane plasticity&lt;/a&gt;. &lt;strong&gt;&lt;em&gt;Journal of Proteomics&lt;/em&gt;&lt;/strong&gt;. 2013, 78:72-82.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;这篇文章是和慕尼黑工业大学（Technische Universität München）合作的一篇文章，使用了Co-IP去拉蛋白，再用LC-MS/MS进行鉴定，Co-IP是鉴定蛋白相互作用的常用手段，当然拉下来的蛋白不见得就是有真实的相互作用，它甚至于可能只是背景污染而已，所以我们需要对拉下来的蛋白进行打分，找出一些可能性比较高的候选蛋白进一步进行验证。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>给你一顶帽子</title>
      <link>https://guangchuangyu.github.io/2017/12/ggimage-hat/</link>
      <pubDate>Wed, 27 Dec 2017 12:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/12/ggimage-hat/</guid>
      <description>&lt;p&gt;圣诞节期间，一个个在@微信官方，要加圣诞帽，这让人想起了以前：&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;今天是马化腾的生日，转发5个群，自动开通一个月的QQ会员&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;这班玩QQ长大的孩子，现在变成了玩微信的油腻中年了。&lt;/p&gt;
&lt;p&gt;做为biobabble公众号的粉丝，我觉得你们是有能力用两三行R代码来给自己加个帽子的。由于我在过圣诞节，所以这篇文章没有能够及时推送出来，就当马后炮吧，不合时宜地调侃一下大家。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>bioSyntax - 针对生物数据的语法高亮</title>
      <link>https://guangchuangyu.github.io/2017/12/biosyntax/</link>
      <pubDate>Fri, 22 Dec 2017 13:50:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/12/biosyntax/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://biosyntax.org/images/sam-less-small.gif&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;对于生信狗，天天黑白命令行，实验室的同事，经常对着我的Emacs说，这么小的字体你看得清吗？我只能无奈地回答，因为我要一个屏幕显示一整个函数。我自己平时写代码也很注意这一点，函数尽量小，太长就要考虑切分成几个函数，我说自己是脑容量不够，写不了长函数。我希望如果有人看我代码，他/她可以看得舒服点，虽然写的不见得好，但起码一个函数，你一个屏幕是装得下的。岁月留给我们的，是越来越厚的镜片！然而最近有一款神器，让我们在命令行里，可以高亮显示生物学常见的数据格式，包括SAM, VCF, GTF, PDB和FASTA。这款神器叫bioSyntax (&lt;a href=&#34;http://bioSyntax.org&#34;&gt;http://bioSyntax.org&lt;/a&gt;) ，看着舒服多了，而且逼格十足，如果大家序列比对看多了，其实都会依赖于看颜色，黑白字体情况下，你很难去区分ATCG，即使有明显的pattern，你也很难看出来。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>130岁了，祝你生快</title>
      <link>https://guangchuangyu.github.io/2017/12/geom-cake/</link>
      <pubDate>Thu, 14 Dec 2017 22:00:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/12/geom-cake/</guid>
      <description>&lt;p&gt;周日是港大医学院的198届毕业典礼，Y叔要去参加，今年也正好是医学院130周年，做为画图界的传说，我决定画一个蛋糕。&lt;/p&gt;
&lt;p&gt;要画蛋糕，这有何难，我们有&lt;code&gt;emojifont&lt;/code&gt;啊，还记得《&lt;a href=&#34;http://mp.weixin.qq.com/s/ARxyTRpMs6OeCqOQPp9OwA&#34;&gt;emojifont新功能（有视频哦）&lt;/a&gt;》一文中的&lt;code&gt;geom_emoji&lt;/code&gt;图层吗？&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>最后的八卦</title>
      <link>https://guangchuangyu.github.io/2017/12/chipseeker-8g/</link>
      <pubDate>Wed, 13 Dec 2017 12:20:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/12/chipseeker-8g/</guid>
      <description>&lt;h2 id=&#34;chipseeker系列传送门&#34;&gt;ChIPseeker系列传送门&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s/lFi1m7k-9t6nD0SER1r1hw&#34;&gt;CS0: ChIPseq从入门到放弃&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://mp.weixin.qq.com/s/vgXrscsUkfYdC5qt_PUNlw&#34;&gt;CS1: ChIPseq简介&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s/D06NEG7blksGugb0srL7KQ&#34;&gt;CS2: BED文件&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://mp.weixin.qq.com/s/vWTf59KDs1lp_sQXjEhI_g&#34;&gt;CS3: peak注释&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://mp.weixin.qq.com/s/_OPzvaEAbiMolCA2mqJXLw&#34;&gt;CS4：关于ChIPseq注释的几个问题&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://mp.weixin.qq.com/s/gDpsdj6cLDtnG1Kla79wLA&#34;&gt;CS5: 吃着火锅，唱着歌，还把分析给做了&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://mp.weixin.qq.com/s/MqpfgkMJSFj0pYwcEjV9kQ&#34;&gt;CS6: ChIPseeker的可视化方法（中秋节的视觉饕餮）&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://mp.weixin.qq.com/s/v61LjQEfyi_CZucHW53ETw&#34;&gt;CS7：Genomic coordination的富集性分析（1）&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s/vbkZrGwD7dZ-OPOiqkyTnA&#34;&gt;CS8：Genomic coordination的富集性分析（2）&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s/98k_L3CmjH817xMF2VfYtA&#34;&gt;CS9: GEO数据挖掘&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;ChIPseeker这个系列，从《&lt;a href=&#34;https://mp.weixin.qq.com/s/lFi1m7k-9t6nD0SER1r1hw&#34;&gt;CS0: ChIPseq从入门到放弃&lt;/a&gt;》到现在CS10，总共11篇，第一篇以八卦开始，我想很有必要以八卦来结束。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ChIPseq-GEO数据挖掘</title>
      <link>https://guangchuangyu.github.io/2017/12/geo-data-mining-for-chipseq/</link>
      <pubDate>Mon, 11 Dec 2017 12:53:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/12/geo-data-mining-for-chipseq/</guid>
      <description>&lt;p&gt;ChIPseeker系列文章已经介绍了很多内容，包括注释的方方面面，也包括强大的可视化功能（《&lt;a href=&#34;http://mp.weixin.qq.com/s/MqpfgkMJSFj0pYwcEjV9kQ&#34;&gt;CS6: ChIPseeker的可视化方法（中秋节的视觉饕餮）&lt;/a&gt;》）。&lt;/p&gt;
&lt;p&gt;今天要介绍一下数据挖掘，从大量已有的数据来产生新的hypothesis。正如我在ChIPseeker的文章里写的：&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;There are increasing evidences shown that combinations of TFs are important for regulating gene expression (Perez-Pinera et al., 2013; Zhu et al., 2008). However, systematically identification of TF interactions by ChIP-seq is still not available. Even if a specific TF binding is essential for a particular regulation was known, we do not have prior knowledge of all its co-factors. There are no systematic strategies available to identified un-known co-factors by ChIP- seq.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;并没有方法可以大规模地预测未知的共同调控因子，而数据挖掘就是要给我们这种预测的能力。&lt;/p&gt;
&lt;p&gt;我当年在写ChIPseeker的时候，我有纠结是写篇Bioinformatics的application note呢，还是写篇长文灌水NAR，毕竟NAR影响因子高一点，最后还是发了Bioinformatics，因为我没钱，囧，Bioinformatics不要版面费啊。然后限于篇幅，ChIPseeker有大量可视化的函数，我在文章中一张图都没放！！！如果当时决定发NAR的话，这个数据挖掘这一块我就会写多点。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>使用外部字体画meme</title>
      <link>https://guangchuangyu.github.io/2017/12/using-external-font-for-meme/</link>
      <pubDate>Thu, 07 Dec 2017 06:31:55 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/12/using-external-font-for-meme/</guid>
      <description>&lt;p&gt;meme无非是照片上加两行字，&lt;a href=&#34;https://cran.r-project.org/web/packages/meme/&#34;&gt;meme&lt;/a&gt;这个包本来是练手之作，用来&lt;a href=&#34;https://guangchuangyu.github.io/2017/10/create-meme-in-r/&#34;&gt;模拟ggplot2的api&lt;/a&gt;。结果我后面又实现了&lt;a href=&#34;https://guangchuangyu.github.io/2017/11/shadow-text-effect-in-grid-and-ggplot2-graphics/&#34;&gt;字体阴影效果&lt;/a&gt;，这次我又带来了外部字体支持。&lt;/p&gt;
&lt;p&gt;加载外部字体在R上面主要有extrafont和showtext两个实现，特别是showtext用起来还是非常简单的。我在meme包里写了&lt;code&gt;font_import&lt;/code&gt;函数，内部就是用showtext，只是简单的包装了一下，这样小白用户可以直接下个字体就开撸。有阴影效果，有&lt;a href=&#34;https://fontmeme.com/fonts/&#34;&gt;搞笑字体&lt;/a&gt;，就万事具备了，这俨然是个专业的meme工具了。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Genomic coordination的富集性分析</title>
      <link>https://guangchuangyu.github.io/2017/12/genomic-coordination-enrichment-analysis/</link>
      <pubDate>Wed, 06 Dec 2017 10:03:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/12/genomic-coordination-enrichment-analysis/</guid>
      <description>&lt;p&gt;在《&lt;a href=&#34;https://mp.weixin.qq.com/s/v61LjQEfyi_CZucHW53ETw&#34;&gt;CS7：Genomic coordination的富集性分析（1）&lt;/a&gt;》说到了seq2pathway这个包，其实是两部曲，seq2gene-&amp;gt;gene2pathway，无非是把测序片段用临近的基因注释，包括和TSS overlap的基因，宿主基因，上下游的基因等，然后拿这些基因跑ORA，做富集，仅此而已，这个包支持的物种极有限，《&lt;a href=&#34;http://mp.weixin.qq.com/s/_OPzvaEAbiMolCA2mqJXLw&#34;&gt;CS4：关于ChIPseq注释的几个问题&lt;/a&gt;》这一文中讲到ChIPseeker支持所有有基因组注释的物种，而《&lt;a href=&#34;http://mp.weixin.qq.com/s/ScwaofLd_ybfECYjL1dGow&#34;&gt;clusterProfiler for enrichment analysis&lt;/a&gt;》也支持所有物种（即使你自己跑的电子注释，也能支持），那么使用ChIPseeker来做基因注释，然后衔接clusterProfiler就可以支持所有物种的测序片段进行功能富集分析了。&lt;/p&gt;
&lt;p&gt;《&lt;a href=&#34;http://mp.weixin.qq.com/s/vWTf59KDs1lp_sQXjEhI_g&#34;&gt;CS3: peak注释&lt;/a&gt;》本身就支持几种注释，另外我写了一个&lt;code&gt;seq2gene&lt;/code&gt;的函数，套用&lt;code&gt;seq2pathway&lt;/code&gt;的思路，把一个基因位置上所有关联的基因全部返回来，我们可以使用它去把基因位置信息转换成基因列表，然后用于富集分析，还是熟悉的味道，还是熟悉的配方🦄&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>visualizing reassortment history using seqcombo</title>
      <link>https://guangchuangyu.github.io/2017/12/visualizing-reassortment-history-using-seqcombo/</link>
      <pubDate>Tue, 05 Dec 2017 11:09:07 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/12/visualizing-reassortment-history-using-seqcombo/</guid>
      <description>&lt;p&gt;Reassortment is an important strategy for influenza A viruses to
introduce a HA subtype that is new to human populations, which creates
the possibilities of pandemic.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://raw.githubusercontent.com/GuangchuangYu/seqcombo/master/vignettes/figures/srep25549-f2.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;A diagram showed above (Figure 2 of &lt;code&gt;doi:10.1038/srep25549&lt;/code&gt;) is widely
used to illustrate the reassortment events. While such diagrams are
mostly manually draw and edit without software tool to automatically
generate. Here, I implemented the &lt;code&gt;hybrid_plot&lt;/code&gt; function for producing
publication quality figure of reassortment events.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;library(tibble)
library(ggplot2)


n &amp;lt;- 8

virus_info &amp;lt;- tibble(
    id = 1:7,
    x = c(rep(1990, 4), rep(2000, 2), 2009),
    y = c(1,2,3,5, 1.5, 3, 4),
    segment_color = list(
        rep(&#39;purple&#39;, n),
        rep(&#39;red&#39;, n),
        rep(&#39;darkgreen&#39;, n),
        rep(&#39;lightgreen&#39;, n),
        c(&#39;darkgreen&#39;, &#39;darkgreen&#39;, &#39;red&#39;, &#39;darkgreen&#39;, &#39;red&#39;, &#39;purple&#39;, &#39;red&#39;, &#39;purple&#39;),
        c(&#39;darkgreen&#39;, &#39;darkgreen&#39;, &#39;red&#39;, &#39;darkgreen&#39;, &#39;darkgreen&#39;, &#39;purple&#39;, &#39;red&#39;, &#39;purple&#39;),
        c(&#39;darkgreen&#39;, &#39;lightgreen&#39;, &#39;lightgreen&#39;, &#39;darkgreen&#39;, &#39;darkgreen&#39;, &#39;purple&#39;, &#39;red&#39;, &#39;purple&#39;))
)

flow_info &amp;lt;- tibble(from = c(1,2,3,3,4,5,6),
                    to = c(5,5,5,6,7,6,7))
hybrid_plot(virus_info, flow_info)
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/Bioconductor/seqcombo/reassortment_files/figure-markdown_strict/unnamed-chunk-2-1.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggplot2/ggtree取子集画图</title>
      <link>https://guangchuangyu.github.io/2017/12/subsetting-in-ggplot2-ggtree/</link>
      <pubDate>Fri, 01 Dec 2017 08:28:48 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/12/subsetting-in-ggplot2-ggtree/</guid>
      <description>&lt;p&gt;取子集对于进化树可视化来说是非常常见的，我们要区分内部节点和外部节点，我们也可能想针对某些特点的节点进行注释。&lt;/p&gt;
&lt;p&gt;ggplot2现在所有图层都不支持直接取子集，所以呢ggtree就自己定义了一些修改的图层，包括&lt;code&gt;geom_text2&lt;/code&gt;, &lt;code&gt;geom_label2&lt;/code&gt;,  &lt;code&gt;geom_point2&lt;/code&gt; 和 &lt;code&gt;geom_segment2&lt;/code&gt;，这些图层和ggplot2的版本唯一差别就是支持取子集。这样对于我们做注释来说，就更方便了。&lt;/p&gt;
&lt;p&gt;比如说我想给内部节点打点，可以用：&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;ggtree&lt;/span&gt;(tree) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;geom_text2&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;aes&lt;/span&gt;(label&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;label, subset&lt;span style=&#34;color:#f92672&#34;&gt;=!&lt;/span&gt;isTip), hjust&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;-.2&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;
        &lt;span style=&#34;color:#a6e22e&#34;&gt;geom_point2&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;aes&lt;/span&gt;(subset&lt;span style=&#34;color:#f92672&#34;&gt;=!&lt;/span&gt;isTip), color&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;red&amp;#34;&lt;/span&gt;, size&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;3&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>再不用担心打不开sci-hub了</title>
      <link>https://guangchuangyu.github.io/2017/11/sci-hub-tor/</link>
      <pubDate>Wed, 22 Nov 2017 11:01:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/11/sci-hub-tor/</guid>
      <description>&lt;p&gt;之前有写过&lt;a href=&#34;https://mp.weixin.qq.com/s/AGQn7Lfn_nHHrtVQyJSTmg&#34;&gt;读文献的文章&lt;/a&gt;，也介绍了&lt;a href=&#34;https://mp.weixin.qq.com/s/TMmsOsEn0wV9yXKOLma3Rw&#34;&gt;如何获取文献&lt;/a&gt;，那是我还在读硕士的时候写的，覆盖了找文献、文献管理、下载文献、订阅期刊等方方面面，说到下文献，最大的神器当然是sci-hub，但是sci-hub的域名sci-hub.cc, sci-hub.bz, sci-hub.io纷纷都沦陷，最近国内有一神器geenmedical，整合了影响因子、引用数等指标，然而这一神器的下文献功能只是提供外链，有一种说法是geenmedical=pubmed+scihub，当然geenmedical的资源还可能来自于百度学术、researchGate等，不都是来自于sci-hub，然而我们必须承认的是最大的文献提供来源必须还得是sci-hub，所以如果sci-hub挂了，基于sci-hub的神器也就神奇不起来了。如果有人跟你说忘记sci-hub吧，用geenmedical，那绝对是标题党！这里并没有说geenmedical不好，它整合了多方面的资源并且本地化得非常好，很适合国内使用。&lt;/p&gt;
&lt;p&gt;比如我在geenmedical里搜clusterProfiler，给出的下载链接第一个就是sci-hub的：&lt;a href=&#34;http://doi.org.sci-hub.cc/10.1089/omi.2011.0118&#34;&gt;http://doi.org.sci-hub.cc/10.1089/omi.2011.0118&lt;/a&gt;，然而这个链接是不可用的！当然它给出了比如百度学术的链接是可以下载到文献的。然而还是那句话，论「海盗精神」我只服sci-hub，虽然我之前也介绍了《&lt;a href=&#34;http://mp.weixin.qq.com/s/aaIby87LSQgxpvCAECFxkw&#34;&gt;sci-hub如果挂了，你还有神器下文献吗？&lt;/a&gt;》，但任何下文献的神器，在sci-hub面前都是渣渣。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggplot2给选定的分面加背景</title>
      <link>https://guangchuangyu.github.io/2017/11/background-rect-for-selected-facet/</link>
      <pubDate>Mon, 20 Nov 2017 00:21:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/11/background-rect-for-selected-facet/</guid>
      <description>&lt;p&gt;我这个公众号不像大多数所谓的生信从入门到精通的各种其实只是搬运点入门教程的群众喜闻乐见的公众号。正如我在《&lt;a href=&#34;http://mp.weixin.qq.com/s/f-c5Q63SY166ZGzYCsqthA&#34;&gt;为什么要开这个公众号&lt;/a&gt;》里说的，这是小众的，有个人色彩的各种原创文。我不可能像其它公众号一样招两小弟当客服，很多人在公众号后台向我扔了许多问题，由于个人精力有限，只能优先解答「知识星球」的问题，上次写的《&lt;a href=&#34;http://mp.weixin.qq.com/s/jegI1wWc7DJzrM7mQfz77Q&#34;&gt;同一数据多变量分组的boxplot?&lt;/a&gt;》，图虽然简单，却穿着好多件马甲，而我把它扒光了给你看🙈&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/zhishixingqiu/ggplot-bg_question.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;上面这个图，你看着高大上吧，我都可以吐它一脸口水。每一个有灰色背景的图，在x轴上violin都够到边界了，其实所有的violin都够到了，这证明什么？每个violin之间其实不可比较！你能想像几个独立的数据，在统一的bin width情况下，画density curve，竟然最高点都一样高吗？显然可能性几乎为0。这个如果使用ggplot2的话，可以使用&lt;code&gt;scale=&#39;width&#39;&lt;/code&gt;强制拉成一样高，但我不推荐，正如我前面说的，不可比较了。默认参数&lt;code&gt;scale=&#39;area&#39;&lt;/code&gt;，积分面积一样，和density curve一样解析，另外的参数&lt;code&gt;scale=&amp;quot;count&amp;quot;&lt;/code&gt;，高度与计数同比例，和histogram一样解析，而&lt;code&gt;scale=&#39;width&#39;&lt;/code&gt;强制拉成一样高，如果没有在显眼处说明，误导性太强。&lt;/p&gt;
&lt;p&gt;画这种图也可以手工拼，这样就简单了。在你需要的情况下，加个灰色背景嘛，最后拼图嘛。当然拼图不一定要在illustrator里拼，比如你用grid，先画好坐标轴，然后水平上定义几个一样大的viewport，每一个violin都画在相应的viewport里面，对于画图函数来说，viewport就是整个画布了（虽然只是画布里的一块区域），所以你要么画violin，要么在画之前先画个矩阵，一路画下来，代码可以直接生成这样的图，但这图每一个violin都是独立画的（当然也不是完全独立，每一个水平上的ylim是有统一的），就算代码一步生成，也跟illustrator里拼没两样。&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;这里我要教你用ggplot2自动生成，其实解决思路早已推送过，请看《&lt;a href=&#34;http://mp.weixin.qq.com/s/PnbasfW4HKILuZNdrLVX_g&#34;&gt;facet_plot：加图层到特定分面，方法二&lt;/a&gt;》，也正如我在《&lt;a href=&#34;http://mp.weixin.qq.com/s/8bzkJY1zzNc83iBUq4Fy1w&#34;&gt;什么！你的图上有一双看不见的手&lt;/a&gt;》里说的，你们以为我在教ggtree，其实同时在教ggplot2。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>不同数据集画出的热图，用同样的颜色区间上色？</title>
      <link>https://guangchuangyu.github.io/2017/11/pheatmap-color-range/</link>
      <pubDate>Mon, 13 Nov 2017 00:21:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/11/pheatmap-color-range/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/R/misc/WechatIMG216.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;这个问题，其实答案就存在于《&lt;a href=&#34;http://mp.weixin.qq.com/s/Xhi_ZkrEzUVdnCu7ECBS4w&#34;&gt;听说你还不会画热图&lt;/a&gt;》，我们先生成一个矩阵：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;set.seed(2017-11-12)
d = data.frame(matrix(rnorm(100), ncol=10))
colnames(d) = paste0(&#39;t&#39;, 1:10)
rownames(d) = paste0(&#39;g&#39;, 1:10)
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;这个矩阵是&lt;code&gt;rnorm&lt;/code&gt;生成的随机数，有正有负，我们再生成一个矩阵，只有正数，并且数值上比第一个矩阵要大：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;d2 = abs(d) * 1.2
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>掐架的额外收获</title>
      <link>https://guangchuangyu.github.io/2017/11/bioc-db-update/</link>
      <pubDate>Sun, 12 Nov 2017 00:21:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/11/bioc-db-update/</guid>
      <description>&lt;p&gt;《&lt;a href=&#34;http://mp.weixin.qq.com/s/miGQs6U1d3aHwcm7vgNCVw&#34;&gt;你昨天才做的分析，可能是几年前的结果！&lt;/a&gt;》这篇文章给大家敲了警钟，各种各样的web-server，要小心看有没有维护更新，有些是五年十年都不更新的，十分可怕。文章虽然讲的是富集分析，但其它分析工具你同样需要小心。&lt;/p&gt;
&lt;p&gt;当然并不是说独立的软件/软件包就一定靠谱，如果软件自己打包了数据，同样要注意数据是否有更新，而如果数据不打包在软件里，而是在线获取，你同样也该留一下心。这也是clusterProfiler做富集分析的优势所在，KEGG数据是在线的，永远是最新的，而GO的数据不在软件包里，而依赖于别的数据包，而这些数据包是社区维护的（相对而言，个人的维护比较难以为继），就确保了数据一直在有更新维护的。&lt;/p&gt;
&lt;p&gt;Bioconductor每半年发行一次，注释包同样每半年更新一次，所以你用clusterProfiler做GO分析，你用的GO数据库不会说超过半年没更新，而不像有些公司给出的结果，落后于这个世界不是一年两年这么简单。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>虐狗节来看一下这个裤衩都不要的故事</title>
      <link>https://guangchuangyu.github.io/2017/11/bmc-protects-paper-of-plagiarism/</link>
      <pubDate>Sat, 11 Nov 2017 20:00:43 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/11/bmc-protects-paper-of-plagiarism/</guid>
      <description>&lt;p&gt;![](&lt;a href=&#34;http://guangchuangyu.github.io/blog_images/R/ppipre/Screenshot&#34;&gt;http://guangchuangyu.github.io/blog_images/R/ppipre/Screenshot&lt;/a&gt; 2017-11-10 00.10.22.png)&lt;/p&gt;
&lt;p&gt;Scientific Report上有一篇文章是抄袭的，然而杂志最终决定不撤稿，而被抄的人是Johns Hopkins的，于是jh的人全都要离开Scientific Report的编委。我也被人抄了不撤稿，然而我人微言轻，不单被编辑部欺负，还要被我们国内生信界的网红欺负。&lt;/p&gt;
&lt;p&gt;SR与jh的事情，我和BMC的故事，是相似的，我们可以想像这样的学术界惨剧比想像中的要多。学术圈，真是有时候得呵呵哒。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>听说你想打水印？</title>
      <link>https://guangchuangyu.github.io/2017/11/watermark/</link>
      <pubDate>Fri, 10 Nov 2017 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/11/watermark/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/R/meme/WechatIMG165.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;正如我在《&lt;a href=&#34;http://mp.weixin.qq.com/s/jDXjkrkq_YVhW-Z5Vx2-Fg&#34;&gt;用R画meme ;)&lt;/a&gt;》里说的，meme包就可以拿来画，当然这个包是设计来画meme的，所以文本只会打在中间，如果你想在右下角之类的，不好意思，我没提供选项让你调文本位置，氮素，meme依然是你的好帮手，怎么说呢，meme不单能帮你读图片，还能用grid画出来，这意味着你可以用&lt;code&gt;grid.text&lt;/code&gt;随便加个文本就OK了。&lt;/p&gt;
&lt;p&gt;实例演示一发：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;library(meme)
u &amp;lt;- system.file(&amp;quot;angry8.jpg&amp;quot;, package=&amp;quot;meme&amp;quot;)
x &amp;lt;- meme(u)
print(x)
grid.text(&amp;quot;biobabble&amp;quot;, x=.9, y=.05, 
	gp=gpar(col=&#39;white&#39;, cex=1.2))
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>BMC journal protects paper of plagiarism</title>
      <link>https://guangchuangyu.github.io/2017/11/bmc-journal-protect-paper-of-plagiarism/</link>
      <pubDate>Thu, 09 Nov 2017 21:51:43 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/11/bmc-journal-protect-paper-of-plagiarism/</guid>
      <description>&lt;p&gt;My friend who doing his PhD study at Johns Hopkins just send me the link about &lt;a href=&#34;https://retractionwatch.com/2017/11/07/17-johns-hopkins-researchers-resign-protest-ed-board-nature-journal/&#34;&gt;a SR paper of plagiarism&lt;/a&gt;. I have very similar experence of &lt;a href=&#34;https://bmcsystbiol.biomedcentral.com/articles/10.1186/1752-0509-7-S2-S8&#34;&gt;a paper published on BMC Systems Biology&lt;/a&gt;, which plagiarized &lt;a href=&#34;https://www.ncbi.nlm.nih.gov/pubmed/20179076&#34;&gt;my work&lt;/a&gt; and the editor just decided to publish an erratum.&lt;/p&gt;
&lt;p&gt;Deng &lt;em&gt;etc.&lt;/em&gt; published an R package, ppiPre, that copied source code of my package, GOSemSim, and pretended that they developed these algorithms by themselves in their paper.&lt;/p&gt;
&lt;p&gt;Here is the screenshot of the source code (left: ppiPre, right: GOSemSim).&lt;/p&gt;
&lt;p&gt;![](&lt;a href=&#34;https://guangchuangyu.github.io/blog_images/screenshots/Screenshot&#34;&gt;https://guangchuangyu.github.io/blog_images/screenshots/Screenshot&lt;/a&gt; 2017-07-17 19.43.51.png)&lt;/p&gt;
&lt;p&gt;You can find out more on &lt;a href=&#34;http://guangchuangyu.github.io/2014/11/proper-use-of-gosemsim/&#34;&gt;my blog post&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;As a developer of several open source software, I am glad that someone find my source code useful and happy if someone use my source code to make something better. But I am not happy if someone copies my source code by removing author information and changing function names to pretend the code was developed by himself. The situation is even worse in academic. Taking someone else&amp;rsquo;s works and passing it off as one&amp;rsquo;s own is definitely plagiarism and not allow in academic.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>一个用不了的R包和一个404的网站</title>
      <link>https://guangchuangyu.github.io/2017/11/scholar/</link>
      <pubDate>Thu, 09 Nov 2017 13:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/11/scholar/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/R/scholar/WechatIMG166.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;正如我在「知识星球」里说的，scholar这个包现在已经死了，因为作者不维护了，除非出现接盘侠。我自己fork了一个，打了补丁，现在是可用的。这个包应该说我用得蛮多的，你看我简历里的引用数柱状图，我不会无聊到过一段时间就去查，然后重新画图的，太low。都是自动化的，我到简历目录下打make指令，就会自动去爬数据、重新画图并生成简历，而我啥都不用干。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>听说你的KEGG分析有大量的基因没注释</title>
      <link>https://guangchuangyu.github.io/2017/11/kegg-gene-annotation/</link>
      <pubDate>Tue, 07 Nov 2017 00:21:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/11/kegg-gene-annotation/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://github.com/GuangchuangYu/clusterProfiler/issues/115&#34;&gt;github上的问题&lt;/a&gt;，问了两个问题，这是其中第二个：&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Meanwhile, when I fed the ENTREZID to enrichKEGG, it show me two unreasonable results:&lt;/p&gt;
&lt;/blockquote&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;kegg_enrich = enrichKEGG(
	gene = new_ids$ENTREZID,
	organism = &#39;hsa&#39;,
	keyType = &#39;ncbi-geneid&#39;,
	pvalueCutoff = 0.05,
	#pAdjustMethod = &#39;BH&#39;,
	#qvalueCutoff = 0.2,
	use_internal_data = FALSE
)
&lt;/code&gt;&lt;/pre&gt;&lt;blockquote&gt;
&lt;/blockquote&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;head(kegg_enrich)
              ID                           Description GeneRatio  BgRatio       pvalue   p.adjust     qvalue
hsa04380 hsa04380            Osteoclast differentiation    14/281 128/7299 0.0003817040 0.04767338 0.04508266
hsa04070 hsa04070 Phosphatidylinositol signaling system    12/281  99/7299 0.0003875885 0.04767338 0.04508266
&lt;/code&gt;&lt;/pre&gt;&lt;blockquote&gt;
&lt;p&gt;I noted that only 281 genes are remained(there are 700+ genes in my list). In case that there is something wrong wtihin my gene list, I also tried my list with DAVID. It gave me reasonable results. So this is my second question, why enrichKEGG cannot recognize my geneids?&lt;/p&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>Pubmed年度趋势</title>
      <link>https://guangchuangyu.github.io/2017/11/pubmed-trend/</link>
      <pubDate>Fri, 03 Nov 2017 14:53:35 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/11/pubmed-trend/</guid>
      <description>&lt;p&gt;在很久很久以前，当我还在用perl的时候，有一个TGen-EUtils的perl模块，可以去爬PubMed，我喜欢用它来画所谓的pubmed趋势，比如说我在2012年的时候，就画了各个组学技术的pubmed趋势，通过每一年的文章发表量来看某个技术到底火不火，走势怎么样。&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2012/10/pubmedtrend.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;当年microarray还特别猛，但显然可以看到二代测序必须要火，也可以看到proteomics在吹了几年牛B之后，有回落的趋势。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>请用事实怼我</title>
      <link>https://guangchuangyu.github.io/2017/11/go-version-issue/</link>
      <pubDate>Thu, 02 Nov 2017 20:23:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/11/go-version-issue/</guid>
      <description>&lt;p&gt;在《&lt;a href=&#34;https://mp.weixin.qq.com/s/miGQs6U1d3aHwcm7vgNCVw&#34;&gt;你昨天才做的分析，可能是几年前的结果！&lt;/a&gt;》这篇文章的开头，我吐槽了WEGO+华大（虽然文章是转载自《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzAxMjQ3MTU5Mg==&amp;amp;mid=2650655271&amp;amp;idx=1&amp;amp;sn=b1dfadd57937c949ba0e8deeac2fdeb6&amp;amp;scene=21#wechat_redirect&#34;&gt;嘉因生物&lt;/a&gt;》，但这段是我给自己加的戏码，广告后面才是原帖内容 -，-）。&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/2017/bgi/1509620511198.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;这只不过是我任性了一番，因为华大的拥护者来骂人了，我真的不理解，如果我说错了，你们可以拿事实啪啪啪地打我脸的，为什么要骂人，所以我任性地再吐一口口水。&lt;/p&gt;
&lt;p&gt;这里我必须承认，我说错了，华大用的WEGO不是那在线版的09年以后就不更新的WEGO，09年人的注释不超过7000个，华大给的报告有12929个（BP），当然也不是最新的，目前org.Hs.eg.db中GO的数据源是2017-03-29, BP的注释有16992个，比华大多了1/3，所以《&lt;a href=&#34;https://mp.weixin.qq.com/s/miGQs6U1d3aHwcm7vgNCVw&#34;&gt;你昨天才做的分析，可能是几年前的结果！&lt;/a&gt;》这篇文章要吐槽的依然对，谁知道差这1/3会发生什么呢。&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;&amp;gt; (16992-12929)/12929
[1] 0.3142548
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>shadow text effect in grid and ggplot2 graphics</title>
      <link>https://guangchuangyu.github.io/2017/11/shadow-text-effect-in-grid-and-ggplot2-graphics/</link>
      <pubDate>Thu, 02 Nov 2017 15:30:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/11/shadow-text-effect-in-grid-and-ggplot2-graphics/</guid>
      <description>&lt;p&gt;After the release of &lt;code&gt;meme&lt;/code&gt; package, I received several feedbacks from users.&lt;/p&gt;
&lt;p&gt;The most usefule one is &lt;a href=&#34;http://disq.us/p/1n9zi69&#34;&gt;the comment&lt;/a&gt; on my blog post:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Greetings Mr. Yu,&lt;/p&gt;
&lt;p&gt;I am very happy that this package exists. Thank you for making it! I would like to request a feature, to ensure the package is able to compete with professional meme-creation tools like memegenerator and paint.net. Since memes often use the font Impact, in white and with black outline, I believe the package would be more powerful if it also did that automatically.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;Regards,&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;The words, &amp;lsquo;compete with professional meme-creation tools&amp;rsquo;, stimulated me to develop text plotting with background outline effect.&lt;/p&gt;
&lt;p&gt;Now this feature is available in &lt;a href=&#34;https://cran.r-project.org/package=meme&#34;&gt;meme&lt;/a&gt; v&amp;gt;=0.0.7, which can be downloaded from CRAN.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>让你画图的文本出现阴影效果</title>
      <link>https://guangchuangyu.github.io/2017/11/shadowtext/</link>
      <pubDate>Wed, 01 Nov 2017 19:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/11/shadowtext/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Sercan Kahveci&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;Greetings Mr. Yu,&lt;/p&gt;
&lt;p&gt;I am very happy that this package exists. Thank you for making it! I would like to request a feature, to ensure the package is able to compete with professional meme-creation tools like memegenerator and paint.net. Since memes often use the font Impact, in white and with black outline, I believe the package would be more powerful if it also did that automatically.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;Regards,&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;Sercan Kahveci, MSc&lt;/p&gt;
&lt;p&gt;Content creator at Questionable Research Memes on Facebook
&lt;a href=&#34;https://www.facebook.com/QResearchMemes/&#34;&gt;https://www.facebook.com/QResearchMemes/&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;上次一篇《&lt;a href=&#34;http://mp.weixin.qq.com/s/jDXjkrkq_YVhW-Z5Vx2-Fg&#34;&gt;用R画meme ;)&lt;/a&gt;》把脸书在做MEME的人都给炸出来了，专业人士给出专业建议，要用Impact字体，并且要让字体出现阴影效果，这真是厉害了，感觉有点神奇，但他一句，这样就可以和专业工具PK了，着实太刺激了，我决定试一试能不能搞个阴影效果。结果还真让我搞成了，文本有一种浮在上面的错觉。&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/R/meme/shadowtext.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;我们知道meme包是grid写的，我的输出是grob对象，当我半夜调试到2点，带着兴奋入睡之后，一点都睡不安稳，早上早早就迷迷糊糊在床上想着，既然我造出了文本阴影效果的grob对象，我应该封装成geom图层，送给ggplot2用户。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>同一数据多变量分组的boxplot?</title>
      <link>https://guangchuangyu.github.io/2017/10/boxplot-multiple-group/</link>
      <pubDate>Mon, 30 Oct 2017 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/10/boxplot-multiple-group/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/R/boxplot_multiple_group_files/WechatIMG111.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;小密圈的问题，不是三两句话可以说明白的事情，必须要写文来解答，上一次写文是《&lt;a href=&#34;http://mp.weixin.qq.com/s/Xhi_ZkrEzUVdnCu7ECBS4w&#34;&gt;听说你还不会画热图&lt;/a&gt;》，里面正好吐槽了某知乎大V的「除了ggplot2之外其它都是鸡肋」，这次正好也可以再次呼应一下。&lt;/p&gt;
&lt;p&gt;这个图明显是R的base graphics做的，图是可圈可点的，能做出这图来，也已经是告别了只会用plot的低级趣味。这其实是4个图拼起来的，第一个图只是多了个y轴而已，它们画起来是一样的，那就是只画boxplot，不画x和y轴，（你可能会说不是有x轴？），x轴是后面再加上去的，而且加x轴的时候，不写labels，只有线条没有文本（你可能又会说明明有文本！），因为&lt;code&gt;axis&lt;/code&gt;这个函数只支持labels要么是水平的，要么是垂直的，旋转某个角度是不支持的，所以labels是额外再打上去的。这里一张小小的图，门道还是挺多的。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>create meme in R</title>
      <link>https://guangchuangyu.github.io/2017/10/create-meme-in-r/</link>
      <pubDate>Wed, 25 Oct 2017 15:13:35 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/10/create-meme-in-r/</guid>
      <description>&lt;p&gt;I developed a tiny toy package, &lt;code&gt;meme&lt;/code&gt;, which is now on CRAN. As it&amp;rsquo;s name indicated, it was designed to create memes, which are captioned photos that are intended to be funny, riduculous.&lt;/p&gt;
&lt;h2 id=&#34;meme&#34;&gt;&lt;code&gt;meme()&lt;/code&gt;&lt;/h2&gt;
&lt;p&gt;The package is quite simple. You can use &lt;code&gt;meme()&lt;/code&gt; function to add meme captions, and this is all the package supposed to do:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;library&lt;/span&gt;(meme)
u &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;http://www.happyfamilyneeds.com/wp-content/uploads/2017/08/angry8.jpg&amp;#34;&lt;/span&gt;
&lt;span style=&#34;color:#a6e22e&#34;&gt;meme&lt;/span&gt;(u, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;code&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;all the things!&amp;#34;&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/R/meme/Figs/unnamed-chunk-2-1.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>webinar录播：plotting tree &#43; data</title>
      <link>https://guangchuangyu.github.io/2017/10/ggtree-webinar-2017/</link>
      <pubDate>Wed, 25 Oct 2017 10:17:48 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/10/ggtree-webinar-2017/</guid>
      <description>&lt;p&gt;据说1024是程序员的节日，就在这一天，Y叔开始了第一次的网络讲座，首次在网络上露面。内容就是上一周预告的《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484958&amp;amp;idx=1&amp;amp;sn=d58e3bb5b43899849101c60efd29df53&amp;amp;chksm=ec43b759db343e4fefd48ec618a5a2d42f46256e7f455bf9373d90157be0b47df9bd7fd069a9#rd&#34;&gt;线上沙龙&lt;/a&gt;》。&lt;/p&gt;
&lt;p&gt;很多人想要学ggplot2 + ggtree，但我的定位不是技术性的培训，而是学术讲座，所以一开始把问题摆出来，是有一些问题存在，有knowledge gap，然后我要去解决它。当然考虑到听众的knowledge gap也很大，我在介绍ggtree的之前，也帮大众撸了一篇R的画图，在这简短的时间里，你应该了解了R几个画图系统的关系，base和grid我在slides里写graphic system，但lattice和ggplot2我写的是data visualization system，我对它们是有区别对待的，像lattice和ggplot2自己是不成一体的，但提供了高阶的数据可视化方法/语法。听完讲座你也应该了解ggplot2，知道要怎样去入门，知道重点该学什么。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>你的图上有一双看不见的手</title>
      <link>https://guangchuangyu.github.io/2017/10/invisible-layer/</link>
      <pubDate>Thu, 19 Oct 2017 12:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/10/invisible-layer/</guid>
      <description>&lt;p&gt;下面这张吐槽LaTeX的图，太深得我心。&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://dirkriehle.com/wp-content/uploads/2016/05/latex.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;而ggplot2这种文本跑出界的事情，也太常见，以至于我在&lt;a href=&#34;https://guangchuangyu.github.io/ggtree/faq/&#34;&gt;ggtree的FAQ&lt;/a&gt;专门指出来，要用&lt;code&gt;xlim&lt;/code&gt;给x轴分配多点空间，这是由于数据是数据空间，而文本是像素空间。你画图的画布由数据空间决定，然后文本就从指定的位置（除了坐标，还取决于你align的方式和adjustment微调）开始打出来，一不小心就打出界了。这一点我在FAQ里，除了告诉你用&lt;code&gt;xlim&lt;/code&gt;解决之外，我也给出了上面的解释，所以我一直强调，不要以为我在教ggtree，我其实是在教ggplot2。&lt;/p&gt;
&lt;p&gt;后面就有人问了ggplot2字体溢出的事情，他所遇到的溢出，似乎更不应该发生，因为是坐标轴上的字体溢出，然而产生的原因是一样的，解决方案也是一样的，请用力猛戳《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484089&amp;amp;idx=1&amp;amp;sn=f6e11d54a18e96a94145a2b802c37dc1&amp;amp;chksm=ec43b3fedb343ae89e3630900033f055af4bbe211897076291e351ae18cc89b2ddf7651ee0be#rd&#34;&gt;ggplot2字体溢出的那点破事&lt;/a&gt;》。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>我的名字和我的姓氏</title>
      <link>https://guangchuangyu.github.io/2017/10/ygc/</link>
      <pubDate>Mon, 16 Oct 2017 18:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/10/ygc/</guid>
      <description>&lt;p&gt;大量的生信公众号在各种linux入门、perl入门、python入门、R入门、软件安装、跑跑示例代码、流程。我自己平时根本不会去看这些生信号，在《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484921&amp;amp;idx=1&amp;amp;sn=b729438c35c7d491ef75fdf8dab5f09f&amp;amp;chksm=ec43b4bedb343da85853e234b5eb86267276e78a6b53dd1360367cca94d764955594ef86e910#rd&#34;&gt;s01 - Counting DNA Nucleotides&lt;/a&gt;》一文发出去后，就被爪哥说不能跟着走低端路线，囧rz&amp;hellip;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2017/WechatIMG93.jpeg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;还好我多半写的是自己的东西，目前还没有掉进「低端」的坑里，今天继续画图，唯有赏心悦目的图能抚慰人心。&lt;/p&gt;
&lt;p&gt;我写了一个包叫《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484164&amp;amp;idx=1&amp;amp;sn=030612f5a84120ef407401ff6fad715f&amp;amp;chksm=ec43b243db343b5524c911327bdcbe5f01034095d549d43d530decc5676faecdbd449dfac026#rd&#34;&gt;ggimage：ggplot2中愉快地使用图片&lt;/a&gt;》，从此图上嵌图（ggplot对象）或图片变得轻而易举。某一天写着玩，写了个《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484079&amp;amp;idx=1&amp;amp;sn=2f37b54ad09b966ccb9e8bf93ebd6643&amp;amp;chksm=ec43b3e8db343afed5d55c25aaaba233f3339686e9eba0e65f004a5ca58ac13bba7ba9b5bacc#rd&#34;&gt;geom_pokemon: 使用pokemon画图&lt;/a&gt;》的图层，引起了人民群众的尖叫，国外有妹纸用来可视化NBA数据《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484149&amp;amp;idx=1&amp;amp;sn=0058b64bc269a05937ba97dccd9c0e23&amp;amp;chksm=ec43b3b2db343aa4799e68b1f5c51cde7b4b5452fe69158b93de6f7b368738ecbc2dcf275abc#rd&#34;&gt;大开眼界+多图慎点：Pokémon x NBA and other fun with ggimage&lt;/a&gt;》，国内有汉子用来可视化复旦大学考研的报考专业《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484594&amp;amp;idx=1&amp;amp;sn=d35474d1ff032b54152935ef55088340&amp;amp;chksm=ec43b5f5db343ce311e0d54e1b936cb4982f952ce38e940ba6c3cf354436c91b1ae22fc17ea1#rd&#34;&gt;你的专业是那一只Pokémon神兽？&lt;/a&gt;》。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>映射变量给axis上色</title>
      <link>https://guangchuangyu.github.io/2017/10/set_axis_text_color/</link>
      <pubDate>Mon, 16 Oct 2017 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/10/set_axis_text_color/</guid>
      <description>&lt;p&gt;小伙伴发来这个文章中的图，想要实现类似的图，用变量给axis text上色，并生成legend：&lt;/p&gt;
&lt;p&gt;![](&lt;a href=&#34;https://guangchuangyu.github.io/blog_images/R/ggplot2/Screenshot&#34;&gt;https://guangchuangyu.github.io/blog_images/R/ggplot2/Screenshot&lt;/a&gt; 2017-07-04 14.10.55.png)&lt;/p&gt;
&lt;p&gt;这个可以说ggplot2是不支持的，aes映射不会被应用于axis上，而theme也不支持aes映射，你只能自己手动搞个color vector传给theme来上色，但这无法生成legend。&lt;/p&gt;
&lt;p&gt;我只能打开脑洞，legend借助于额外的图层来生成，但这个额外的图层又不是我们想要在图形上展示的，这又是个无米之炊，我能想到的就是让图层透明，实际有，但你看不到，当然这样自动生成的legend也会看不到，但legend可以后面再修改，于是这不支持的事情，就通过变通变得可能：&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;require&lt;/span&gt;(ggplot2)

&lt;span style=&#34;color:#a6e22e&#34;&gt;set.seed&lt;/span&gt;(&lt;span style=&#34;color:#ae81ff&#34;&gt;2017-07-04&lt;/span&gt;)
d &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;data.frame&lt;/span&gt;(x &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;letters&lt;/span&gt;[1&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;5&lt;/span&gt;], y &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;rnorm&lt;/span&gt;(&lt;span style=&#34;color:#ae81ff&#34;&gt;5&lt;/span&gt;), 
		group &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;sample&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;c&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Control&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Treatment&amp;#34;&lt;/span&gt;), &lt;span style=&#34;color:#ae81ff&#34;&gt;5&lt;/span&gt;, replace&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;TRUE&lt;/span&gt;),
		type &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;sample&lt;/span&gt;(&lt;span style=&#34;color:#66d9ef&#34;&gt;LETTERS&lt;/span&gt;[1&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;], &lt;span style=&#34;color:#ae81ff&#34;&gt;5&lt;/span&gt;, replace&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;TRUE&lt;/span&gt;)
)

p &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;ggplot&lt;/span&gt;(d, &lt;span style=&#34;color:#a6e22e&#34;&gt;aes&lt;/span&gt;(x,y)) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
	&lt;span style=&#34;color:#a6e22e&#34;&gt;geom_col&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;aes&lt;/span&gt;(fill&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;group))
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;这个代码很好懂，画一个柱状图，按&lt;code&gt;group&lt;/code&gt;上色。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>enrichGO出不来结果？没结果也是正确的结果</title>
      <link>https://guangchuangyu.github.io/2017/10/enrichgo-more-conserve/</link>
      <pubDate>Mon, 09 Oct 2017 13:31:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/10/enrichgo-more-conserve/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Dear Dr. Guangchuang Yu, I write to you regarding a doubt concerning the enrichGO function from Clustalprofiler package. I have been used this package before, but now I&amp;rsquo;m using the same R script and I have an error message.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;This is the command I use:&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;go.bp &amp;lt;- enrichGO(gene = gene.df$ENSEMBL, universe = universe.ENSEMBLID, keytype = &amp;lsquo;ENSEMBL&amp;rsquo;, OrgDb = org.Ce.eg.db, ont = &amp;lsquo;BP&amp;rsquo;, pAdjustMethod = &amp;lsquo;BH&amp;rsquo;, pvalueCutoff = 0.01, qvalueCutoff = 0.05, readable=T)&lt;/p&gt;
&lt;/blockquote&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;and the error is the following one:&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;No gene set have size &amp;gt; 10 &amp;hellip;
&amp;ndash;&amp;gt; return NULL&amp;hellip;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;My input list is attached to this email (101 genes in total). When I use this list in a web resource such as GOrilla it gives to me the proper GO terms.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;Thank you very much in advance. Best regards,&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;María&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;最近clusterProfiler用户的问题，这个问题还蛮普遍。这个我在《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484414&amp;amp;idx=1&amp;amp;sn=096f758f04f875e25c333c345f530742&amp;amp;chksm=ec43b2b9db343baf4e2a8640f48e7e72b3ef1b057c91c68905debb2bb54e5d2fdda62438628a#rd&#34;&gt;why clusterProfiler fails&lt;/a&gt;》中也有谈到，并不是能出结果就是好的。没有结果也是一种结果。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>如何假装假期还在工作</title>
      <link>https://guangchuangyu.github.io/2017/10/ssh-on-android/</link>
      <pubDate>Wed, 04 Oct 2017 00:49:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/10/ssh-on-android/</guid>
      <description>&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247483886&amp;amp;idx=1&amp;amp;sn=cb76891dff5787025f6b99cdcc723d86&amp;amp;chksm=ec43b0a9db3439bfcec1c9ac3c0d00e6190cf4d3d02d9d3dc767007e0ff68b4fbd8064bb0f77#rd&#34;&gt;CS0: ChIPseq从入门到放弃&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484054&amp;amp;idx=2&amp;amp;sn=9a42f1094349a0bd09a5e0b7c44595e0&amp;amp;chksm=ec43b3d1db343ac7e11d92eda3eb1837aab46f79bb109e6cdbba466e4693d041a87fa698ef1b&#34;&gt;我在MSnbase里做了什么？&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484727&amp;amp;idx=1&amp;amp;sn=a70494626e7c329addea51ac6b82c578&amp;amp;chksm=ec43b470db343d6661ba2498e5b03d300f281cb24c82dff0b53fac62b55831ab6207e9a0c20e#rd&#34;&gt;博士养成记&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;我在上面三篇文章里，都吐槽了张大砖家，这里穿插个故事，当时有门课是去嘉道理農場，在很偏的山上，而且是封闭式，再者离港大很远。选课是先告诉砖家的，上课前也跟砖家讲，然后第一天上课了，人不在实验室，第二天砖家就来了下面这样的信：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>CS6: ChIP数据可视化</title>
      <link>https://guangchuangyu.github.io/2017/10/chipseeker-visualization/</link>
      <pubDate>Sun, 01 Oct 2017 11:44:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/10/chipseeker-visualization/</guid>
      <description>&lt;p&gt;2017眼看要结束，立下写《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247483886&amp;amp;idx=1&amp;amp;sn=cb76891dff5787025f6b99cdcc723d86&amp;amp;chksm=ec43b0a9db3439bfcec1c9ac3c0d00e6190cf4d3d02d9d3dc767007e0ff68b4fbd8064bb0f77#rd&#34;&gt;CS0: ChIPseq从入门到放弃&lt;/a&gt;》的flag还没完成，当时ChIPseeker是33个引用，现在已经80了，时间过得好快。&lt;/p&gt;
&lt;p&gt;最近放羊的Jimmy给我发来了一个截屏：&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/Bioconductor/ChIPseeker/vis/WechatIMG51.jpeg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;说了一篇新文章，大段在称赞ChIPseeker：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>听说你还不会画heatmap</title>
      <link>https://guangchuangyu.github.io/2017/09/dose-simplot/</link>
      <pubDate>Sat, 30 Sep 2017 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/09/dose-simplot/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/Bioconductor/DOSE/simplot/WechatIMG52.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;群众纷纷表示图二是Excel画的，我觉得也是！Excel是生物学家的最爱啊。虽然做生信的人都看不上，最主要是没有记录，不具备可重复性。但现实就是大家都爱Excel。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ko数据库ID转换</title>
      <link>https://guangchuangyu.github.io/2017/09/ko-id-conversion/</link>
      <pubDate>Wed, 27 Sep 2017 19:11:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/09/ko-id-conversion/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Since the clusterProfiler is a very useful tools for GO and Kegg annotation.At present I want to use it to enrich for kegg result while only have the KO number ,So I want to convert the KO number to the pathway function,Is there have any function or methods in the software can convert it?any help will be appreciated&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;a href=&#34;https://github.com/GuangchuangYu/clusterProfiler/issues/99&#34;&gt;这个问题&lt;/a&gt;问说他想转KO到通路，首先这是一个常见的错误，很多人分不清&lt;code&gt;K&lt;/code&gt;和&lt;code&gt;ko&lt;/code&gt;，所以在我告诉他可以把&lt;code&gt;K number&lt;/code&gt;转成&lt;code&gt;ko pathway&lt;/code&gt;的时候，我先指出他的错误。&lt;/p&gt;
&lt;p&gt;&lt;code&gt;ko&lt;/code&gt; is actually pathway map. I think you are talking about &lt;code&gt;K&lt;/code&gt; number mapping to &lt;code&gt;ko&lt;/code&gt; pathway.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;bitr_kegg&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;K00844&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;kegg&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Path&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ko&amp;#34;&lt;/span&gt;)
     kegg    Path
&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;  K00844 ko00010
&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;  K00844 ko00051
&lt;span style=&#34;color:#ae81ff&#34;&gt;3&lt;/span&gt;  K00844 ko00052
&lt;span style=&#34;color:#ae81ff&#34;&gt;4&lt;/span&gt;  K00844 ko00500
&lt;span style=&#34;color:#ae81ff&#34;&gt;5&lt;/span&gt;  K00844 ko00520
&lt;span style=&#34;color:#ae81ff&#34;&gt;6&lt;/span&gt;  K00844 ko00521
&lt;span style=&#34;color:#ae81ff&#34;&gt;7&lt;/span&gt;  K00844 ko00524
&lt;span style=&#34;color:#ae81ff&#34;&gt;8&lt;/span&gt;  K00844 ko01100
&lt;span style=&#34;color:#ae81ff&#34;&gt;9&lt;/span&gt;  K00844 ko01110
&lt;span style=&#34;color:#ae81ff&#34;&gt;10&lt;/span&gt; K00844 ko01120
&lt;span style=&#34;color:#ae81ff&#34;&gt;11&lt;/span&gt; K00844 ko01130
&lt;span style=&#34;color:#ae81ff&#34;&gt;12&lt;/span&gt; K00844 ko01200
&lt;span style=&#34;color:#ae81ff&#34;&gt;13&lt;/span&gt; K00844 ko04066
&lt;span style=&#34;color:#ae81ff&#34;&gt;14&lt;/span&gt; K00844 ko04910
&lt;span style=&#34;color:#ae81ff&#34;&gt;15&lt;/span&gt; K00844 ko04930
&lt;span style=&#34;color:#ae81ff&#34;&gt;16&lt;/span&gt; K00844 ko04973
&lt;span style=&#34;color:#ae81ff&#34;&gt;17&lt;/span&gt; K00844 ko05230
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>正经的图千篇一律，不正经的叔万里挑一</title>
      <link>https://guangchuangyu.github.io/2017/09/geofacet_index/</link>
      <pubDate>Wed, 20 Sep 2017 14:13:35 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/09/geofacet_index/</guid>
      <description>&lt;p&gt;![](&lt;a href=&#34;https://guangchuangyu.github.io/blog_images/R/geofacet/Screenshot&#34;&gt;https://guangchuangyu.github.io/blog_images/R/geofacet/Screenshot&lt;/a&gt; 2017-10-17 10.31.23.png)&lt;/p&gt;
&lt;p&gt;这个题目可以放好多不正经的图，我在这个公众号里面已经写过太多，比如《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247483816&amp;amp;idx=1&amp;amp;sn=cbfbc284f4edb165ac65f7926f7f8fcc&amp;amp;chksm=ec43b0efdb3439f91ec4f570f7be65e442e21e403481b969d69449464ae1986c7983551de04d#rd&#34;&gt;邪恶的曲线&lt;/a&gt;》和它的3D版本，《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484823&amp;amp;idx=1&amp;amp;sn=4af972da15535c1d7dcf837ace320592&amp;amp;chksm=ec43b4d0db343dc6ec2e622523a5aabb67f25e4b9e4b93a67ab37125570fbab907741351da18#rd&#34;&gt;3D版邪恶的曲线&lt;/a&gt;》，但这里不涉及太多，只用&lt;code&gt;geofacet&lt;/code&gt;这个包为例。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>再见joyplot</title>
      <link>https://guangchuangyu.github.io/2017/09/goodbye-joyplot/</link>
      <pubDate>Fri, 15 Sep 2017 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/09/goodbye-joyplot/</guid>
      <description>&lt;p&gt;微信公众号平台大部分人都是抄来抄去的二手资料，像joyplot这种特别新的东西，就很难看到，我试着搜索了一下，发现只有三篇，都是我写的。&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484586&amp;amp;idx=1&amp;amp;sn=2c4aaca92147d901fb5421cdb99d16de&amp;amp;chksm=ec43b5eddb343cfb34c907ddfdba74e129ee7ef896219a888a56b36738a0f6062bb2cf0ab99f#rd&#34;&gt;joyplot：一种波涛汹涌，哦不对，是山峰叠峦的可视化方式&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484682&amp;amp;idx=1&amp;amp;sn=21944039080612bed8bda7b3070015b3&amp;amp;chksm=ec43b44ddb343d5bcba5c22e33b6b26ce8bfee6e7b913115c19e0e14e930699ab602445d0e89#rd&#34;&gt;ggjoy facet with ggtree&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484750&amp;amp;idx=1&amp;amp;sn=19aa83580ad91e18d3fe23cc42675628&amp;amp;chksm=ec43b409db343d1f189bf1d1e6499ac8bd034ce52e90454d7e2b568b6901b5d2f5bdf31fa887#rd&#34;&gt;joyplot：GSEA的结果也能快乐起来&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;</description>
    </item>
    
    <item>
      <title>R, python喊你回家吃饭啦</title>
      <link>https://guangchuangyu.github.io/2017/09/rtichoke/</link>
      <pubDate>Wed, 13 Sep 2017 13:37:55 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/09/rtichoke/</guid>
      <description>&lt;p&gt;在《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484507&amp;amp;idx=1&amp;amp;sn=295454a59613bfd977f407958bec787e&amp;amp;chksm=ec43b51cdb343c0acea87661fe5144a5817503a2fdc8f316d56fd28d33291084bc718330c428#rd&#34;&gt;你所不知道的，R的N种打开方式&lt;/a&gt;》一文中，我介绍了R的N种界面，这里将介绍一个用python写的极其现代化的R命令行界面，rtichoke（之前叫rice）之于R，就像ipython之于python一样。&lt;/p&gt;
&lt;h2 id=&#34;特性&#34;&gt;特性&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;轻量，不需要编译&lt;/li&gt;
&lt;li&gt;多行编辑，这点很重要啊，长长的命令可以换行后，随便回去编辑前面的指令&lt;/li&gt;
&lt;li&gt;语法高亮，这可是R命令行所没有的，看起来舒服多了&lt;/li&gt;
&lt;li&gt;自动补齐，减少输入&lt;/li&gt;
&lt;li&gt;支持bracketed paste mode，也就是说你copy-paste了有换行符的字符串，不会拷进去就自动执行了&lt;/li&gt;
&lt;li&gt;支持Windows, macOS 和 Linux&lt;/li&gt;
&lt;li&gt;支持vi, emacs等编辑模式&lt;/li&gt;
&lt;li&gt;可以多种高亮模式&lt;/li&gt;
&lt;/ul&gt;</description>
    </item>
    
    <item>
      <title>highlight clade of unrooted tree</title>
      <link>https://guangchuangyu.github.io/2017/09/highlight-clade-of-unrooted-tree/</link>
      <pubDate>Tue, 12 Sep 2017 20:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/09/highlight-clade-of-unrooted-tree/</guid>
      <description>&lt;p&gt;最初github上用户（&lt;a href=&#34;https://github.com/JustGitting&#34;&gt;@JustGitting&lt;/a&gt;）报告说&lt;code&gt;geom_hilight&lt;/code&gt;和&lt;code&gt;geom_cladelabel&lt;/code&gt;不能用于unrooted树。详见：&lt;a href=&#34;https://github.com/GuangchuangYu/ggtree/issues/118&#34;&gt;https://github.com/GuangchuangYu/ggtree/issues/118&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;我表示这确实是不行的，然后这就变成了feature request。我继续表示unrooted tree在ggtree中的实现并不好，我只实现了equal angle algorithm，在写注释图层之前，如果我有时间的话，我希望可以先实现更好的layout algorithm。&lt;/p&gt;
&lt;p&gt;然后JustGitting表示，他发现python的ETE和R的ape，在无根树的可视化上好像都不太行。问我有什么unrooted的layout algorithm，有没有什么参考文献，或许他可以帮忙实现，因为他觉得ggtree是最成熟的软件。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>gseaplot自定义颜色</title>
      <link>https://guangchuangyu.github.io/2017/09/color-in-gseaplot/</link>
      <pubDate>Mon, 11 Sep 2017 19:11:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/09/color-in-gseaplot/</guid>
      <description>&lt;p&gt;《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484730&amp;amp;idx=1&amp;amp;sn=48b8c24b6cfb6162f8fb3f3861ddfe1b&amp;amp;chksm=ec43b47ddb343d6b37581fa81b0bf11b5141a446333b1b961ef1ad4f80da4c4732d7bc3432c2#rd&#34;&gt;听说你有RNAseq数据却不知道怎么跑GSEA&lt;/a&gt;》一文有小伙伴问封面的gseaplot能否换颜色，于是我就随手支持了。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>设置ggplot所有字体</title>
      <link>https://guangchuangyu.github.io/2017/09/ggplot2-set-font/</link>
      <pubDate>Mon, 04 Sep 2017 16:14:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/09/ggplot2-set-font/</guid>
      <description>&lt;p&gt;最近公众号「生信媛」和「生信宝典」的小伙伴在说ggplot2无法一次性设置所有字体，&lt;code&gt;theme&lt;/code&gt;只能设置axis text, title这些，而搞不了&lt;code&gt;geom_text&lt;/code&gt;，&lt;code&gt;geom_text&lt;/code&gt;必须要手工输入&lt;code&gt;family=XXX&lt;/code&gt;来设置，因为不能使用&lt;code&gt;theme&lt;/code&gt;来更换，也就是说没办法通过后处理来设定，比较麻烦。&lt;/p&gt;
&lt;p&gt;这显然是不对的，后处理必须可以的，一次性满足所有愿望也只是因为没人写个神奇的函数而已。于是我就动手写了个&lt;code&gt;set_font&lt;/code&gt;的函数。&lt;/p&gt;
&lt;p&gt;假设我们有下图：&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;library&lt;/span&gt;(ggplot2)
d &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;data.frame&lt;/span&gt;(x&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;rnorm&lt;/span&gt;(&lt;span style=&#34;color:#ae81ff&#34;&gt;10&lt;/span&gt;), y&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;rnorm&lt;/span&gt;(&lt;span style=&#34;color:#ae81ff&#34;&gt;10&lt;/span&gt;), lab&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;LETTERS&lt;/span&gt;[1&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;10&lt;/span&gt;])
p &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;ggplot&lt;/span&gt;(d, &lt;span style=&#34;color:#a6e22e&#34;&gt;aes&lt;/span&gt;(x, y)) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
    &lt;span style=&#34;color:#a6e22e&#34;&gt;geom_text&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;aes&lt;/span&gt;(label&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;lab, color&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;lab), size&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;10&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
	&lt;span style=&#34;color:#a6e22e&#34;&gt;geom_text&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;aes&lt;/span&gt;(y, x, label&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;lab), size&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;3&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>3D版邪恶的曲线</title>
      <link>https://guangchuangyu.github.io/2017/09/3d-breast/</link>
      <pubDate>Mon, 04 Sep 2017 14:13:35 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/09/3d-breast/</guid>
      <description>&lt;p&gt;我的公众号biobabble第一篇原创文章《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247483816&amp;amp;idx=1&amp;amp;sn=cbfbc284f4edb165ac65f7926f7f8fcc&amp;amp;chksm=ec43b0efdb3439f91ec4f570f7be65e442e21e403481b969d69449464ae1986c7983551de04d#rd&#34;&gt;邪恶的曲线&lt;/a&gt;》，因为太邪恶，当时只推送给男性关注者，由于不是推送给所有人，所以历史记录是翻不到的，之前有再文字推送一下链接，结果评论区全是差评，我也是蛮囧rz的…&lt;/p&gt;
&lt;p&gt;无意中我又翻到了一张2012年2月份画的3D版本，尽管你们要差评，还是想分享一下。代码就在截屏之中，想玩的话，可以照着输入，支持鼠标旋转哦，可以慢慢把玩（太邪恶了）。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>你所没见过的苹果</title>
      <link>https://guangchuangyu.github.io/2017/08/apple-logo-emoji/</link>
      <pubDate>Tue, 29 Aug 2017 17:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/08/apple-logo-emoji/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/MISC/iphone5s.jpeg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;5s无缘无故突然就自带3D效果，可是苹果没送我3D眼镜啊！做为一个果粉，自从乔帮主离去之后，对苹果是越来越无爱了。&lt;/p&gt;
&lt;p&gt;anyway，对于这部陪伴许久的手机，还是要纪念一下的。&lt;/p&gt;
&lt;p&gt;《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484489&amp;amp;idx=1&amp;amp;sn=36bbdee1da96aee301f217e61cc8e3b5&amp;amp;chksm=ec43b50edb343c186a58494e32ffe7df6ae9d960a37772fb5887a9c3f7461ab906b90d1a34f0#rd&#34;&gt;按地理位置分面&lt;/a&gt;》一文最后我埋了个伏笔，写到最后的时候，我想到的是可以拿来画个元素周期表，但懒得搞，在《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484506&amp;amp;idx=1&amp;amp;sn=59bc85733a37c4aa8036e43c6d3e7523&amp;amp;chksm=ec43b51ddb343c0b7417b8fe924a86d0d974163b39fe6c8aa72504d1e0ef4c3393aa41659de4#rd&#34;&gt;ggplot2分面之像素艺术&lt;/a&gt;》一文里用一只火鸡展示了用图来拼像素画的思路，回应了前文的伏笔。今天继续展示一个像素画，为了纪念我的iphone5S，当然我要画个苹果🍎出来。&lt;/p&gt;
&lt;p&gt;这里的图，用的是emoji来画，如果你还不会用emoji来画图装逼，赶紧戳《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484416&amp;amp;idx=1&amp;amp;sn=c089403a2b8ab03d241b6d99ef138f50&amp;amp;chksm=ec43b547db343c51bdae5f76b399072629720cf646ddc1c0b758c7c76d57e8b1e35b47221cf6&#34;&gt;看完此文, 你也能够大开脑洞, 上升逼格&lt;/a&gt;》。然后用&lt;code&gt;geofacet&lt;/code&gt;来拼出像素画，这个时候，你应该想到可以拿来拼你的照片，画个某个形状的照片墙了。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>joyplot for GSEA result</title>
      <link>https://guangchuangyu.github.io/2017/08/joyplot-for-gsea-result/</link>
      <pubDate>Sun, 20 Aug 2017 20:51:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/08/joyplot-for-gsea-result/</guid>
      <description>&lt;p&gt;I am very glad to find that someone figure out &lt;a href=&#34;https://stackoverflow.com/questions/45384281/ggjoy-facet-with-ggtree&#34;&gt;how to use ggjoy with ggtree&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://i.stack.imgur.com/U7D3j.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;I really love ggjoy and believe it can be a good tool to visualize gene set enrichment (GSEA) result. DOSE/clusterProfiler support several visualization methods.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>关于重用代码与文章抄袭</title>
      <link>https://guangchuangyu.github.io/2017/08/source-code-reuse/</link>
      <pubDate>Sun, 20 Aug 2017 20:27:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/08/source-code-reuse/</guid>
      <description>&lt;p&gt;《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484733&amp;amp;idx=1&amp;amp;sn=b43739e02ef7e7892f196aa51a1c2e59&amp;amp;chksm=ec43b47adb343d6c98b240a0dfed9abe1ab46e230535a44f2b47bf69cc7b45520f7c7fd38231#rd&#34;&gt;大学教授力挺抄袭，强行洗地到裤衩都不要了，到底图什么？&lt;/a&gt;》这篇文章发出来之后，引起大家讨论，有一些小伙伴截了屏给我看。所以我想有必要再讲几句，我这篇文章写&lt;strong&gt;两个方面&lt;/strong&gt;，一方面是重用代码，一方面是文章抄袭，这两方面可以是不相关的，这里的文章抄袭并不特指你抄了代码。&lt;/p&gt;
&lt;p&gt;X教授《&lt;a href=&#34;http://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484733&amp;amp;idx=2&amp;amp;sn=b6c3a81f38c0f60433e8ccd721a7ca3b&amp;amp;chksm=ec43b47adb343d6c0bee4ae222af03353329173b9ae87c588d6bb19f95619dc46b829d0af1b6#rd&#34;&gt;如何姿势正确的使用他人代码？&lt;/a&gt;》，总结起来两个点，一是开源代码随便用，二是文章有引用/致谢就OK。这两个点都是错误的。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>大学教授力挺抄袭，强行洗地到裤衩都不要了，到底图什么？</title>
      <link>https://guangchuangyu.github.io/2017/08/plagiarism/</link>
      <pubDate>Sat, 19 Aug 2017 10:52:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/08/plagiarism/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;连遮羞布都不要，难道这是个一被子的故事?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;事情开始于我整理并曝光了西安电子科技大学一个讲师读在职博士期间抄袭了两篇文章，并顺利拿到学位晋升为副教授的故事。&lt;/p&gt;
&lt;h2 id=&#34;这个故事很精彩&#34;&gt;这个故事很精彩&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;亮点1&lt;/strong&gt;: 期间发现了一条抄袭链，GOSim被DOSim抄，而DOSim又被HPOSim抄，抄袭者都在文章中把抄来的算法实现当成自己做的东西来介绍。&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;亮点2&lt;/strong&gt;: ppiPre抄袭GOSemSim的文章，我跟BMC Systems Biology反馈了，而编辑部竟然各种包庇，最后抄袭者两面三刀，和编辑部黑箱操作，在未告知我的情况下，出来一个洗地的Erratum，把抄袭说成不好意思，忘记引用了。&lt;/p&gt;
&lt;p&gt;整个过程连载于以下四篇文章中：&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484602&amp;amp;idx=1&amp;amp;sn=d81f54bd2cd04a97d54ae13f4aa44f29&amp;amp;chksm=ec43b5fddb343ceb140b3302e3ad592f82572506cb3d99f0d1c65c9829cf5564948e53d73da8#rd&#34;&gt;[连载1]：学术期刊的学术不端，你见过吗？&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484618&amp;amp;idx=1&amp;amp;sn=bcb696bba156bc433cae638a461bdcdb&amp;amp;chksm=ec43b58ddb343c9b546cf7c4b3d032da610ce89d0b8c1778cb723cf74cdfa11c11bbedf3557a#rd&#34;&gt;[连载2]：Editor你的心不会痛吗？&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484629&amp;amp;idx=1&amp;amp;sn=f6224e30a6a4fde1461a050b642d80ec&amp;amp;chksm=ec43b592db343c84f70689c39525a29d69f69fe4a62f76e69ecbb18634cd6baef0500a7fe6a6#rd&#34;&gt;[连载3]：辣眼睛，一篇抄袭引发的系列血案！&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484637&amp;amp;idx=1&amp;amp;sn=973088de67527548429542d45344c714&amp;amp;chksm=ec43b59adb343c8c2f25bc077695a5f6d6c6b59650102670dbfe7cf9b00a32698775593722c5#rd&#34;&gt;[连载4]：我像是一颗棋，进退任由你决定&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;如果想要分享这整个过程，可以分享以下这个汇总的文章：&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484640&amp;amp;idx=1&amp;amp;sn=478f77b8f03eb9793bafc8f18e126097&amp;amp;chksm=ec43b5a7db343cb11fc9e0c232e0de0db7ec444abf5e8e3bd703f83a3cb31695f10359b47b8f#rd&#34;&gt;从业超过10年，未见过如此厚颜无耻之人&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;</description>
    </item>
    
    <item>
      <title>Galaxy-ChIPseq流程</title>
      <link>https://guangchuangyu.github.io/2017/08/galaxy-chipseeker/</link>
      <pubDate>Tue, 15 Aug 2017 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/08/galaxy-chipseeker/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;这篇文章介绍如果把ChIPseeker搬上galaxy，和galaxy上其它软件一起拼成流程，跑一个ChIPseq注释的流程，从fastq文件开始，比对生成bam文件，peak calling生成bed文件，基因组注释，一个完整的流程，这个流程一旦设置好，每次跑都只是点点鼠标就可以了。
本文额外附送：&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;如何把R程序变成命令行程序&lt;/li&gt;
&lt;li&gt;如何把命令行程序搬上galaxy (知名的程序都有人搬好，但自己的程序还是需要学一下怎么配置的）&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
&lt;p&gt;Galaxy可以说是低端生信从业者杀手，如果你的能力只是跑跑流程，galaxy完全可以取代你的工作。&lt;/p&gt;
&lt;p&gt;如果你是苦逼的生物研究生，苦于要自己分析数据，不会跑命令行程序，对各种参数表示晕菜，galaxy也是拯救你的神器，如同有个做生信的人在旁边帮助你，参数你点点菜单就可以了，跟程序变运行又可以了，流程自己都可以设计并一键运行。&lt;/p&gt;
&lt;h2 id=&#34;安装galaxy&#34;&gt;安装galaxy&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;requirements: python 2.7 and git&lt;/li&gt;
&lt;li&gt;only three steps&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;克隆galaxy项目&#34;&gt;克隆galaxy项目&lt;/h3&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;git clone https://github.com/galaxyproject/galaxy/
cd galaxy
&lt;span style=&#34;color:#75715e&#34;&gt;## switch to master branch, stable release&lt;/span&gt;
git checkout -b master origin/master
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>博士养成记</title>
      <link>https://guangchuangyu.github.io/2017/08/get-phd-degree/</link>
      <pubDate>Mon, 14 Aug 2017 10:30:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/08/get-phd-degree/</guid>
      <description>&lt;h2 id=&#34;期望中的博士生活是这样子&#34;&gt;期望中的博士生活是这样子&lt;/h2&gt;
&lt;p&gt;![](&lt;a href=&#34;https://guangchuangyu.github.io/blog_images/MISC/phd/2016-01-05&#34;&gt;https://guangchuangyu.github.io/blog_images/MISC/phd/2016-01-05&lt;/a&gt; 00.58.47.jpg)&lt;/p&gt;
&lt;h2 id=&#34;然而真实的生活却是&#34;&gt;然而真实的生活却是：&lt;/h2&gt;
&lt;p&gt;![](&lt;a href=&#34;https://guangchuangyu.github.io/blog_images/MISC/phd/2015-06-23&#34;&gt;https://guangchuangyu.github.io/blog_images/MISC/phd/2015-06-23&lt;/a&gt; 11.31.59.jpg)&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>听说你有RNAseq数据却不知道怎么跑GSEA</title>
      <link>https://guangchuangyu.github.io/2017/08/prepare-genelist/</link>
      <pubDate>Thu, 10 Aug 2017 19:11:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/08/prepare-genelist/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Dear GuangChuangyu,&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;I&amp;rsquo;m trying to use the clusterProfiler package for GSE analysis on DGE data obtained from RNAseq.
While I can run enrichKEGG, I&amp;rsquo;m unable to run gseKEGG basically because I don&amp;rsquo;t know how to obtain an order ranked gene list.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;I work on R. I have a dataframe or matrix with gene names, log2 fold change values, pvalues and adjusted pvalues among others.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;How can I get the order ranked gene list to feed in gseKEGG?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;Moreover what is the more reliable way to obtain functional insight about each sample? enrichKEGG or gseKEGG?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;Thank you in advance for your help.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;best regards&lt;/p&gt;
&lt;p&gt;bruno saubaméa&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;今天收到一封来自Université Paris Descartes的求助信，这个问题我被问过好多次了，显然很多新手都有这问题，根本不知道该怎么跑GSEA，搞不清GSEA的输入是什么。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>祝你们缠缠绵绵到天涯</title>
      <link>https://guangchuangyu.github.io/2017/08/response-to-sciencenet-blog-post/</link>
      <pubDate>Tue, 08 Aug 2017 17:52:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/08/response-to-sciencenet-blog-post/</guid>
      <description>&lt;p&gt;薛宇这篇《&lt;a href=&#34;http://blog.sciencenet.cn/home.php?mod=space&amp;amp;uid=404304&amp;amp;do=blog&amp;amp;id=1069933&#34;&gt;BMC Systems Biology没有学术不端&lt;/a&gt;》写作水平还真是高啊，先来个不拉干的小事情，用了软件没引用，来铺垫并以此对抄袭事情进行定位/定性。再来一堆论据和结论不相关的逻辑来论证，好像很有道理的样子，不明真相（没有读我的4篇连载）的群众很容易就掉坑里了。&lt;/p&gt;
&lt;p&gt;首先讲了他和R教授的故事，那只不过是用了工具没引用而已，和抄袭是两码事！试图把抄袭写成与此类似的「忘记引用」！&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;比方说我给R教授写信，就只是问有没有用我的工具。都是聪明人，话不需要说的那么透，点到为止就得了。那您要问，如果人家不回信或者耍赖说没用呢？很简单，三天不回信我会立马写信杂志社，说作者用了我的东西并且刻意没有引用也没有致谢，态度极其恶劣建议撤稿，并且把我三天前发的信抄给编辑作为证据。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;为了把抄袭这种严重的事情与用了工具没引用这种简直太常见且不值一提的小事做类比，薛宇教授是用心良苦啊，把小事给说大了！&lt;/p&gt;
&lt;p&gt;这就是牛逼之处，我不得不服，用小事与大事类比，将大事说小！将小事说大，让大事化小于无形中。&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;有德国学者使用了GOSemSim的代码设计了预测蛋白质相互作用的工具IntScore，发表在2012年的核酸研究上，作者专门写了一节来介绍GO的语义学相似性并且标明引用，所以这篇文章符合学术规范，没有问题。我们再看看DOSim，这篇文章里注明了GO注释的分析使用的是GOSim并且加了引用，所以也没有问题。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;这段话很有水平，首先是&lt;strong&gt;不对等类比&lt;/strong&gt;，以2012年NAR的符合学术规范的文章来类比一篇抄袭文章，试图化抄袭于无形中。&lt;/p&gt;
&lt;p&gt;我们来看所谓的一节&lt;strong&gt;专门介绍&lt;/strong&gt;和标明引用是怎样的：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>有魔性的图来一发</title>
      <link>https://guangchuangyu.github.io/2017/07/magick-add-gif/</link>
      <pubDate>Fri, 28 Jul 2017 07:09:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/magick-add-gif/</guid>
      <description>&lt;p&gt;不知不觉中我已经介绍了很多R包，有学术上的&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247483886&amp;amp;idx=1&amp;amp;sn=cb76891dff5787025f6b99cdcc723d86&amp;amp;chksm=ec43b0a9db3439bfcec1c9ac3c0d00e6190cf4d3d02d9d3dc767007e0ff68b4fbd8064bb0f77#rd&#34;&gt;ChIPseeker&lt;/a&gt;、&lt;a href=&#34;http://mp.weixin.qq.com/s/Uhx3l3lKQS88OJ4SHntkNg&#34;&gt;treeio&lt;/a&gt;、&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247483962&amp;amp;idx=1&amp;amp;sn=7240c1fe0e09a142ef95ac594922b890&amp;amp;chksm=ec43b37ddb343a6bc7c2633597aba751b7f257846d26bc0060b7782ecd3ae20fece8085f0295&#34;&gt;ggtree&lt;/a&gt;、
&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484374&amp;amp;idx=1&amp;amp;sn=f946f3539a752b09a94b5e160e87368e&amp;amp;chksm=ec43b291db343b871a1f10ca31d6ef94e9da4485043ed374c9739689d02072be92a34ca4e863#rd&#34;&gt;clusterProfiler&lt;/a&gt;、
&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484054&amp;amp;idx=1&amp;amp;sn=c9c45157bfb60d5143e5d467ebfe5a86&amp;amp;chksm=ec43b3d1db343ac74cbc7a4f0bbe8b9a09346c2becbce33e5f8c070b333a2195adb8741e9e82&#34;&gt;GOSemSim&lt;/a&gt;、&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484018&amp;amp;idx=1&amp;amp;sn=53281ebf18b52518bc14dc83a0709bf9&amp;amp;chksm=ec43b335db343a23465208b47327088d054f8eed64f7d7137b09d01ca414c08fb17804fd19ce&#34;&gt;seqcombo&lt;/a&gt;和&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484054&amp;amp;idx=2&amp;amp;sn=9a42f1094349a0bd09a5e0b7c44595e0&amp;amp;chksm=ec43b3d1db343ac7e11d92eda3eb1837aab46f79bb109e6cdbba466e4693d041a87fa698ef1b&#34;&gt;MSnbase&lt;/a&gt;等，当然免不了有&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247483948&amp;amp;idx=1&amp;amp;sn=e57e385ada66c991a5c3cf6eb48f7169&amp;amp;chksm=ec43b36bdb343a7dbd39574bb6b02cf8057a4d068399630e77e0580113a2807bb8c34edafbf0&#34;&gt;吐槽&lt;/a&gt;还有&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484640&amp;amp;idx=1&amp;amp;sn=478f77b8f03eb9793bafc8f18e126097&amp;amp;chksm=ec43b5a7db343cb11fc9e0c232e0de0db7ec444abf5e8e3bd703f83a3cb31695f10359b47b8f#rd&#34;&gt;抄袭&lt;/a&gt;。&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484641&amp;amp;idx=1&amp;amp;sn=3ff11eef4cf48ebc6c2d1b06be950834&amp;amp;chksm=ec43b5a6db343cb04355c149b52bbd9bcb11b7983e48ddb5d40b85081003937d5e582b0f69b5&#34;&gt;有学R的&lt;/a&gt;和&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484173&amp;amp;idx=1&amp;amp;sn=ad1817e4acd1362428b3beaa1cd4fede&amp;amp;chksm=ec43b24adb343b5cad6c7ff528182e9c95f0f292044399e127d7495c77bbe2e1cbccb095179c&#34;&gt;更新R包&lt;/a&gt;，也有&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484109&amp;amp;idx=1&amp;amp;sn=9988b955cb4a995dfcfbe31f31d929da&amp;amp;chksm=ec43b38adb343a9cc2ce4ab9fabf3e6ff1db82f6627c91a1035ef94279c6d51e72ffea247f1a&#34;&gt;桌面小工具&lt;/a&gt;，还有画图的&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247483941&amp;amp;idx=1&amp;amp;sn=bb352b5d74797715a9759f64765e49f6&amp;amp;chksm=ec43b362db343a7433d23dd081da263a062e944664ced85d82643eb6e963bccc5d35b43617a8#rd&#34;&gt;ggplot2&lt;/a&gt;、&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247483955&amp;amp;idx=1&amp;amp;sn=0b753422e337e8dd63056d62af9b9e80&amp;amp;chksm=ec43b374db343a62b102a22bc1ebc288c5c4c0ac27db4228bd5214b54b59fa20a948348cebdd&#34;&gt;怎么配色&lt;/a&gt;、&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484079&amp;amp;idx=1&amp;amp;sn=2f37b54ad09b966ccb9e8bf93ebd6643&amp;amp;chksm=ec43b3e8db343afed5d55c25aaaba233f3339686e9eba0e65f004a5ca58ac13bba7ba9b5bacc#rd&#34;&gt;嵌入图片&lt;/a&gt;(比如pokemon)， 以及&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484416&amp;amp;idx=1&amp;amp;sn=c089403a2b8ab03d241b6d99ef138f50&amp;amp;chksm=ec43b547db343c51bdae5f76b399072629720cf646ddc1c0b758c7c76d57e8b1e35b47221cf6&#34;&gt;emoji作图&lt;/a&gt;，也有好玩的&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484504&amp;amp;idx=1&amp;amp;sn=9ce4f3f59d41a27ec3f14c6e77f29a75&amp;amp;chksm=ec43b51fdb343c097ebdaf29ca1eef27c4ea2405555ea2a685f2815c212e93afa337886e1a23&#34;&gt;贴纸&lt;/a&gt;和&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247483868&amp;amp;idx=1&amp;amp;sn=412e13481ad636032125a035bf2216b0&amp;amp;chksm=ec43b09bdb34398d060b1898d286b84975e578c1230da0ce2782d56278a6ce0ee95c0965ac5d&#34;&gt;装逼利器&lt;/a&gt;。&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;今天要介绍另外一个R包，magick，是R里面玩图片的利器，今天要讲的是在静态图片上加动态图片，这样我们平时画一些学术的图，就可以加点搞笑的动态元素上去，有利于在博客和公众号上装逼。&lt;/p&gt;
&lt;p&gt;无非是给我一张静态图当背景，再来一张动态图加在上面，为了让代码可以重用，首先打包个小函数：&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;add_gif &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;function&lt;/span&gt;(bg_file, gif_file, out_file, offset, bg_size&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;500&amp;#34;&lt;/span&gt;, gif_size&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;150&amp;#34;&lt;/span&gt;) {
	&lt;span style=&#34;color:#a6e22e&#34;&gt;library&lt;/span&gt;(magick)
	p &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;image_read&lt;/span&gt;(bg_file)
	g &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;image_read&lt;/span&gt;(gif_file)
	g &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;image_scale&lt;/span&gt;(g, gif_size)

	background &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;image_background&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;image_scale&lt;/span&gt;(p, bg_size), &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;white&amp;#34;&lt;/span&gt;, flatten &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;TRUE&lt;/span&gt;)

	frames &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;lapply&lt;/span&gt;(g, &lt;span style=&#34;color:#a6e22e&#34;&gt;function&lt;/span&gt;(frame) {
  		&lt;span style=&#34;color:#a6e22e&#34;&gt;image_composite&lt;/span&gt;(background, frame, offset &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; offset)
	})

	animation &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;image_animate&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;image_join&lt;/span&gt;(frames))
	&lt;span style=&#34;color:#a6e22e&#34;&gt;image_write&lt;/span&gt;(animation, out_file)
}
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;然后就可以来玩了，首先用上次讲到的dotplot做为底图，再从网上找一个动图，调用函数，bingo:&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>听说你也在画dotplot，但是我不服!</title>
      <link>https://guangchuangyu.github.io/2017/07/clusterprofiler-dotplot/</link>
      <pubDate>Thu, 27 Jul 2017 07:05:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/clusterprofiler-dotplot/</guid>
      <description>&lt;p&gt;陈同的‘生信宝典’公众号出了篇《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5MTcwNjA4NQ==&amp;amp;mid=2247483978&amp;amp;idx=1&amp;amp;sn=e0c158c0e92375553036cc37f4987e40&amp;amp;chksm=ec0dc7c0db7a4ed6ac593493b7d8b52f11f2feb92d24fa00d19527fbb6f95b24f7e313ef9440#rd&#34;&gt;R语言学习 - 富集分析泡泡图&lt;/a&gt;》，搞个shell脚本，一步绘图。讲了这个脚本可以适用于clusterProfiler和其它软件的富集结果。&lt;/p&gt;
&lt;p&gt;浑身都是硬伤，我都不想吐槽，但由于作者邀请我提点，那就吐槽模式全开。&lt;/p&gt;
&lt;h2 id=&#34;一个command出图小白已经哭晕&#34;&gt;一个command出图，小白已经哭晕&lt;/h2&gt;
&lt;p&gt;从出的图看，应该是ggplot2画的（就算猜错，要吐槽的依然正确），小白在web-server上做了分析，存结果为xls文件，拿你这脚本，一跑报错。读xls文件（别告诉我你跟用户说读xls但其实是个tsv）和画图的依赖关系没解决！用户友好在那里？不要告诉我你的脚本0依赖，有个shell就能跑，即使我们熟悉的各种命令，很多都是独立程序，不关shell什么事。&lt;/p&gt;
&lt;h2 id=&#34;所谓的一步出图&#34;&gt;所谓的一步出图&lt;/h2&gt;
&lt;p&gt;既然讲了clusterProfiler，那么clusterProfiler用户笑而不语了。我们用dotplot不也是一条命令出图，为什么要退出R，去跑你的shell脚本，这过程还得转换数据，存储数据。最后的这一步，是前面+N步为代价的。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>听说你也在读文献</title>
      <link>https://guangchuangyu.github.io/2017/07/ferret/</link>
      <pubDate>Wed, 26 Jul 2017 07:05:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/ferret/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/MISC/noidea.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;做为生物狗，我时常不知道自己在干什么，包括读文献，费了老大劲读一篇文献，然后经常也不明白人家在说什么。懒人需要借助神器，本公众号已经介绍了好几个神器，江湖传说收集7大神器，可以召唤出paper，渡自己毕业。&lt;/p&gt;
&lt;h2 id=&#34;拿到一篇文献先问一句牛逼吗靠谱吗&#34;&gt;拿到一篇文献，先问一句，牛逼吗？靠谱吗？&lt;/h2&gt;
&lt;p&gt;我拿ARID1A去pubmed搜，第一篇文章《ARID1A-mutated ovarian cancers depend on HDAC6 activity》为例，2017年7月24号才上线的文章，请看下图：&lt;/p&gt;
&lt;p&gt;![](&lt;a href=&#34;https://guangchuangyu.github.io/blog_images/2017/ferret/Screenshot&#34;&gt;https://guangchuangyu.github.io/blog_images/2017/ferret/Screenshot&lt;/a&gt; 2017-07-26 19.31.32.png)&lt;/p&gt;
&lt;p&gt;IMPACT这里有期刊的影响因子20分，文章在社交网站上传播指数Altmetric 54分，文章在文献管理Mendeley中被收藏2次。这是3天前的文章，所以指数还不高，试想一下，文章传播越广，收藏人数越多，必定也就越重要，这给了我们评估文章的第一印象。这是3天前的文章，所以没有引用，如果有文章引用，这个神器还会列出来呢。&lt;/p&gt;
&lt;p&gt;注意到AUTHORS没有？如果作者有ORCID主页的话，直接链接过去，我们可以去看作者们的publication列表、教育背景、工作经历等信息，牛人为自己带盐，牛人的文章我们更愿意相信。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>搞大你的点，让我们画真正的气泡图</title>
      <link>https://guangchuangyu.github.io/2017/07/scale-size/</link>
      <pubDate>Tue, 25 Jul 2017 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/scale-size/</guid>
      <description>&lt;p&gt;在《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484089&amp;amp;idx=1&amp;amp;sn=f6e11d54a18e96a94145a2b802c37dc1&amp;amp;chksm=ec43b3fedb343ae89e3630900033f055af4bbe211897076291e351ae18cc89b2ddf7651ee0be#rd&#34;&gt;ggplot2字体溢出的那点破事&lt;/a&gt;》一文里，我介绍了字体溢出的解决方案。在《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247483972&amp;amp;idx=1&amp;amp;sn=fa1f4b6299f94eeb52baf5bda6a5ff6b&amp;amp;chksm=ec43b303db343a150806b3b1ab22a1df1c90405235bb399b155f7c50de2a0a23faf2f4ad0beb#rd&#34;&gt;wrapping labels in ggplot2&lt;/a&gt;》一文中介绍了怎么把长文本截断自动换行，这些都是非常常见的问题，最近关于溢出就又有人提问了：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>非模式基因GO富集分析：以玉米为例&#43;使用OrgDb</title>
      <link>https://guangchuangyu.github.io/2017/07/clusterprofiler-maize/</link>
      <pubDate>Mon, 24 Jul 2017 08:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/clusterprofiler-maize/</guid>
      <description>&lt;p&gt;模式生物做什么都简单，非模式生物则很多缺少注释，没有注释你就没法做，只能是借助于各种软件比如blastgo，自己跑电子注释。但今天要讲的不是这种情况，很多物种还是有注释的，只是你有时候不知道该去那里下载，或者你有数据，却不知道该怎么用！很多的软件都是针对模式生物的，或者针对某一些类型的非模式生物，能够支持多种非模式生物，能够支持用户自己的注释文件的软件相对来讲，就非常少有了，然而clusterProfiler就是这类少有的软件之一。&lt;/p&gt;
&lt;h2 id=&#34;获得orgdb&#34;&gt;获得OrgDb&lt;/h2&gt;
&lt;p&gt;今天要讲的是通过OrgDb来做GO分析，这是clusterProfiler的&lt;strong&gt;enrichGO&lt;/strong&gt;函数所支持的背景注释，Bioconductor自带20个OrgDb可供使用，多半是模式生物，难道我们要做的物种不在这20个里面就不行了吗？显然不是的，clusterProfiler能支持的物种我自己都数不过来。&lt;/p&gt;
&lt;p&gt;我们可以通过AnnotationHub在线检索并抓取OrgDb，比如这里以玉米为例：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>听说你想学R</title>
      <link>https://guangchuangyu.github.io/2017/07/swirl/</link>
      <pubDate>Sun, 23 Jul 2017 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/swirl/</guid>
      <description>&lt;h2 id=&#34;先来点八卦&#34;&gt;先来点八卦&lt;/h2&gt;
&lt;p&gt;当年学R的时候，并没有现在这么多的书籍，老用户一般都知道丁国徽，因为他翻译了诸如《R导论》之类的文档，属于最早的中文材料了。跟生物狗有关的中文书有两本，一本是《R语言及Bioconductor在基因组分析中的应用》，这本我在2006年的时候看过，被坑大发了，里面逻辑混乱、错误满篇。&lt;/p&gt;
&lt;p&gt;以下这段豆瓣书评可以说很好的总结了这本书 &lt;a href=&#34;https://book.douban.com/review/3017404/#comments&#34;&gt;https://book.douban.com/review/3017404/#comments&lt;/a&gt;:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;首先，打开前言，读者们会发现“编写本书，参加这些工作的教师和研究生有15人之多”。当然，名字后面带头衔的最后都在出现在封面了。也就是说由12位&amp;quot;无名的岳武穆“研究生同学造就了3名”有名的岳武穆“之砖家叫兽。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;然后，本书共24章，模12为零，当然，这只是一个巧合，只是暗合天命罢了。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;最搞笑的就是这本书的编排和审校，十分差，许多小错误，就好像从没有审过一样。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;譬如第13页上，对order()函数的介绍，居然有这么句绕口令“x[order(x)]等效于order(x)&amp;quot;,当然其实等效的是 sort(x).&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;其他的诸如第17页上&amp;gt;=的打印错误，就不一一细表了。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;最搞笑的就是只有三页的第4章，在数组、函数的介绍之前，就开始讲“聚集计算”！！！然后再来讲解语言基本的语法。。。。
这种“由深入浅，化简单为复杂，化复杂为天书”之功力，更让吾辈叹服砖家叫兽吞云吐雾之神功。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;作为一本实例讲解的书，根本就没有提供源码和实例样本，也就说，根本就是没头没脑的演示。有点专业精神好么，好歹也是本标价68的书，当然只有400页草纸， 本科生水平的语言文档翻译。&lt;/p&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>我像是一颗棋子，进退任由你决定</title>
      <link>https://guangchuangyu.github.io/2017/07/un-fucking-believable/</link>
      <pubDate>Fri, 21 Jul 2017 21:51:43 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/un-fucking-believable/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;we’re talking about people who already are skating on the ethical edge (as scientists, we should always respond to serious criticism; if we don’t, that’s bordering on ethical violation already) &amp;ndash; &lt;a href=&#34;http://www.stat.columbia.edu/~gelman/&#34;&gt;Andrew Gelman&lt;/a&gt;对此事的评论&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;我原以为邓岳是个学生，我的本意是要给他一个教训，制止这种行为，我不出来给他这个教训，早晚他也会为自己的投机付出代价，而且如果以后出现多次抄袭，直接会导致无法继续在学术界生存。后来我发现他还是个讲师，我觉得更不应该了，编辑部必须要对这件事做出处罚。这就是我的本意，让邓岳认识到错误，并为此付出应有的代价。&lt;/p&gt;
&lt;h2 id=&#34;搞得我像祥林嫂一样到处找人说&#34;&gt;搞得我像祥林嫂一样到处找人说&lt;/h2&gt;
&lt;p&gt;然而&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484618&amp;amp;idx=1&amp;amp;sn=bcb696bba156bc433cae638a461bdcdb&amp;amp;chksm=ec43b58ddb343c9b546cf7c4b3d032da610ce89d0b8c1778cb723cf74cdfa11c11bbedf3557a#rd&#34;&gt;编辑一直不做为&lt;/a&gt;，就逼得我只能借助于舆论，我本无意于去网上传播这件事，我写的博客，都是针对编辑部，最后我对编辑提议的处理方式表达不满之后，编辑就&lt;strong&gt;消失了&lt;/strong&gt;，再也不回应邮件。我只能再写博客，再发动舆论，联系之前高调出来说撤稿了43篇文章的那些编辑，推特上也骚扰他们。微博上也AT西电官方微博，求转发之类的。虽然我没有想去闹大事情（尼马我也不想花时间扯这些蛋啊），但BMC就是逼着我跟他斗，而事情闹越大，对抄袭的人来说，越是不利，搞不好学术界就不用混了。谁都不傻，所以终于坐不住给我写信。&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/Bioconductor/GOSemSim/2017-07-20-001828_1280x800_scrot.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;其中说到“1、2月份和您邮件沟通”，只是说了按照CRAN policy改了代码，并把我列为作者，而后面我回应把我名字从软件包作者中去掉而已。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;他的邮件大概讲了和编辑并无操作，软件包已经按要求更新，犯错是源自于无知。&lt;/p&gt;
&lt;h2 id=&#34;这事最后怎么处理&#34;&gt;这事最后怎么处理？&lt;/h2&gt;</description>
    </item>
    
    <item>
      <title>辣眼睛，一篇抄袭引发的系列血案！</title>
      <link>https://guangchuangyu.github.io/2017/07/plagiarism-chain/</link>
      <pubDate>Thu, 20 Jul 2017 21:51:43 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/plagiarism-chain/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;50%的利润,它就铤而走险；&lt;/p&gt;
&lt;p&gt;100%的利润,它就敢践踏一切人间法律；&lt;/p&gt;
&lt;p&gt;300%的利润,它就敢犯任何罪行,甚至绞首的危险.&lt;/p&gt;
&lt;p&gt;&amp;ndash;马克思 《资本论》&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/R/hposim_dosim/hposim_paper.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;ppiPre抄袭GOSemSim，然后我发现他还发了一个叫HPOSim的R包，又是语义相似性度量，我的第一反应是必须还抄我的，他要是有能力写出来，就不会抄GOSemSim了。然而我看了一下代码，确实不是抄我的！&lt;strong&gt;这他妈就奇了怪了!&lt;/strong&gt;&lt;/p&gt;
&lt;h2 id=&#34;必须还是抄的&#34;&gt;必须还是抄的！&lt;/h2&gt;
&lt;p&gt;做语义相似性度量也就那么几个包，我看了一遍之后，发现&lt;strong&gt;HPOSim&lt;/strong&gt;抄了&lt;strong&gt;DOSim&lt;/strong&gt;，你妹啊，用心良苦，同样/相似的东西换不同的包来抄！抄袭惯犯了，事实证明，走捷径的人，是不可能好好走路的，一旦尝到了甜头，必然是铤而走险！&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;以下两个截屏，大家感受一下，左边是HPOSim，右边是DOSim：&lt;/strong&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Editor你的良心不会痛吗？</title>
      <link>https://guangchuangyu.github.io/2017/07/bmc_plagiarism_2/</link>
      <pubDate>Wed, 19 Jul 2017 21:51:43 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/bmc_plagiarism_2/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;抄袭的是&lt;strong&gt;西安电子科技大学&lt;/strong&gt;的讲师，靠着两三篇抄袭的文章，已经是副教授了。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;这种抄袭的事情就应该暴光，这个事件中，更可恶的是BMC，BMC这种保护抄袭的行为更应该暴光，大家不要再给BMC送钱了，还不如发PLoS One。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;公众号有人评论说：&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/Bioconductor/GOSemSim/WechatIMG2.jpeg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;这竟然也被捕捉到了，确实他在2012年的时候，就在copy我的代码，然后打R包的时候，还请教了我：&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/Bioconductor/GOSemSim/ppiPre_dengyue.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;h2 id=&#34;抄了我的代码之后厚颜无耻地感谢我说学了很多东西他的良心真的不会痛吗&#34;&gt;抄了我的代码，之后厚颜无耻地感谢我说学了很多东西，他的良心真的不会痛吗？&lt;/h2&gt;
&lt;p&gt;&lt;img src=&#34;https://media.giphy.com/media/EvsmQokxE8wi4/giphy.gif&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>饼图版气泡图</title>
      <link>https://guangchuangyu.github.io/2017/07/pie-version-of-bubble-plot/</link>
      <pubDate>Wed, 19 Jul 2017 12:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/pie-version-of-bubble-plot/</guid>
      <description>&lt;p&gt;在《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484164&amp;amp;idx=1&amp;amp;sn=030612f5a84120ef407401ff6fad715f&amp;amp;chksm=ec43b243db343b5524c911327bdcbe5f01034095d549d43d530decc5676faecdbd449dfac026#rd&#34;&gt;ggimage：ggplot2中愉快地使用图片&lt;/a&gt;》一文中，我展示了「嵌套式绘图」，中间生成了多个饼图，再用这些产生的饼图用于做图，绘制出饼图版的气泡图：&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://raw.githubusercontent.com/Lchiffon/ggimage-md-for-COS/master/figures/us_crime.png&#34; alt=&#34;嵌套式绘图演示：用饼图来画气泡图&#34;&gt;&lt;/p&gt;
&lt;p&gt;当时还通过每次只画一个州的数据，来演示制作动图：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>学术期刊的学术不端，你见过吗？</title>
      <link>https://guangchuangyu.github.io/2017/07/bmc_plagiarism_1/</link>
      <pubDate>Tue, 18 Jul 2017 21:51:43 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/bmc_plagiarism_1/</guid>
      <description>&lt;h2 id=&#34;编辑部的恶才是最大的恶&#34;&gt;编辑部的恶才是最大的恶！&lt;/h2&gt;
&lt;p&gt;大家是否还记得2015年BioMed Central高调地撤稿了43篇文章，站在道德制高点对审稿过程进行了指责，吐了学术不端一脸口水？&lt;/p&gt;
&lt;p&gt;![](&lt;a href=&#34;https://guangchuangyu.github.io/blog_images/screenshots/Screenshot&#34;&gt;https://guangchuangyu.github.io/blog_images/screenshots/Screenshot&lt;/a&gt; 2017-07-17 19.34.25.png)&lt;/p&gt;
&lt;p&gt;就在这个时候，我写信去&lt;strong&gt;BMC Systems Biology&lt;/strong&gt;告别人抄袭，编辑部信誓旦旦，他们对这种事情是非常认真对待的，然而接下来的剧情却反转了，在我证据甩他们一脸的时候，他们拖着不处理，拖多久呢，&lt;strong&gt;超过1年！&lt;strong&gt;一直在给抄袭者洗地，最好在没有告知我的情况下，静悄悄地出了个所谓的&lt;/strong&gt;erratum&lt;/strong&gt;。&lt;/p&gt;
&lt;p&gt;erratum是什么？字典里这样写：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;erratum |ɛˈrɑːtəm|
noun (pl.errata |ɛˈrɑːtə| )
an error in printing or writing.
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;我告的是抄袭，plagiarism:&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;plagiarism |ˈpleɪdʒərɪz(ə)m|
noun [ mass noun ]
the practice of taking someone else&#39;s work or ideas and passing them off as one&#39;s own. 
&lt;/code&gt;&lt;/pre&gt;&lt;h3 id=&#34;结果plagiarism到了编辑部那里变成了erratum&#34;&gt;结果&lt;strong&gt;plagiarism&lt;/strong&gt;到了编辑部那里变成了&lt;strong&gt;erratum&lt;/strong&gt;.&lt;/h3&gt;</description>
    </item>
    
    <item>
      <title>度娘才是最大的老司机</title>
      <link>https://guangchuangyu.github.io/2017/07/baiduyun/</link>
      <pubDate>Mon, 17 Jul 2017 13:40:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/baiduyun/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Linux是生信从业者最好的操作系统，我觉得对新手最大的安利是大家常用的软件都可以在linux上爽快地用！之前介绍了&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484544&amp;amp;idx=1&amp;amp;sn=f22444670bec8505090cf377de98b6f4&amp;amp;chksm=ec43b5c7db343cd1f7b3e516e7110f7aa25d11cc6c7fd741808cf70548a1d0e4a3cb76aa9236#rd&#34;&gt;QQ&lt;/a&gt; 、&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484423&amp;amp;idx=1&amp;amp;sn=311c627bb70e6fc626bb1f014ec0a976&amp;amp;chksm=ec43b540db343c56fb01f86851c0a4b685351b860d0c9ac2f9709857428b4b76b85bf2bc8b49&amp;amp;scene=21#wechat_redirect&#34;&gt;微信&lt;/a&gt;、&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484004&amp;amp;idx=1&amp;amp;sn=ef769333f07137b83daf9f338ec18eba&amp;amp;chksm=ec43b323db343a35da859d08110d480296b3c95a99240b0ea7336ffbdfd465ef59e6f92d67ff#rd&#34;&gt;迅雷&lt;/a&gt;，这次将介绍度娘的网盘云管家。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;h2 id=&#34;老司机带带你&#34;&gt;老司机带带你&lt;/h2&gt;
&lt;p&gt;各种音乐客户端我都没装，看到朋友圈有分享音乐的，偶尔手贱点进去，通常都会弹出来说告诉我，我所在的区域不支持！尼玛！这世界除了翻墙之外，还有翻回去的，到了墙内网络上音乐、视频才可以听可以看。某一天我想下个专辑放手机上吧，网络上各种搜索，都无法下载，各种会员制、付费、论坛经验值神马的，于是我怒了，找了个磁力链，扔给度娘，度娘&lt;strong&gt;1秒钟&lt;/strong&gt;就给我下好了，你没看错，度娘下东西是秒下！&lt;/p&gt;
&lt;p&gt;Linux上链接有软链接和硬链接之分，软链接就是大家熟悉的’快捷方式‘，而硬链接则是真正意义上的物理指向，所有链接都是真实的，但电脑上有一份拷贝，但凡有一个链接还存在，文件就存在。云盘肯定是类似这样的‘硬链接’，你把别人云盘里的资源保存在你的云盘里，它消耗了你的空间，而实际上对于云盘供应商，零消耗！云盘里有大量的资源，什么东西能吸引用户？色情、电影、盗版软件这些绝对占大头，度娘给了大家下载BT的功能，现在又有下载磁力链的功能，简直分分种满足宅男所有愿望！但凡你要下的东西是存在于度娘的云盘里的，它瞬间就可以给你一个硬链接，所以下东西都是秒下！&lt;/p&gt;
&lt;p&gt;之前有师弟在微信群里问那里可以下到illustrator，被我笑说做为汉子怎么好意思在群里问师姐下盗版，不会下也默默地上淘宝买啊，也就几块钱的事。其实这些上网随便找个BT或磁力链，交给度娘，秒下。即使是很老的BT种子，已经没源了，度娘也是秒下。度娘才是最大的老司机，从此你不再也没理由看不到小电影、看不到盗版碟、下不了盗版软件、听了不盗版专辑。度娘喊你上车！一次满足你所有愿望！&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>你的专业是那一只Pokémon神兽？</title>
      <link>https://guangchuangyu.github.io/2017/07/pokemon/</link>
      <pubDate>Thu, 13 Jul 2017 10:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/pokemon/</guid>
      <description>&lt;h2 id=&#34;啥都不说先上图&#34;&gt;啥都不说，先上图&lt;/h2&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/R/ggimage/1208212267.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Sci-hub如果挂了，你还有神器下文献吗？</title>
      <link>https://guangchuangyu.github.io/2017/07/unpaywall/</link>
      <pubDate>Tue, 11 Jul 2017 10:40:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/unpaywall/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;在《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247483956&amp;amp;idx=1&amp;amp;sn=16df120e86b3e66395ce69c3abf76715&amp;amp;chksm=ec43b373db343a6581301f52c923c7506e0f0789d5f0792fbf59da44f8b29b833cdbc46ddfc2#rd&#34;&gt;如何获取文献&lt;/a&gt;》一文中，我介绍了获取文献的方方面面，从搜索、文献管理、订阅、个性人推荐到下载。本文再继续说说文献下载神器。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Sci-hub无疑现在是很多苦逼科研工作者所依赖的最大神器，然而最近败诉给爱思唯尔出版社，赔1500万美元，这点钱显然是不能够搞垮sci-hub的，但是&lt;strong&gt;败诉&lt;/strong&gt;本身给大家带来的信号对sci-hub的影响会更大，必须更大！美国化学学会几天前也发起了对Sci-Hub的诉讼！sci-hub很有可能在败诉的影响下，被群起而攻之，最终被各大出版社给掐死。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>joyplot：一种波涛汹涌，哦不对，是山峰叠峦的可视化方式</title>
      <link>https://guangchuangyu.github.io/2017/07/ggjoy/</link>
      <pubDate>Tue, 11 Jul 2017 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/ggjoy/</guid>
      <description>&lt;p&gt;最近推特上在讨论的一种叫做joyplot的作图方式，如果我们按照正常的画法，这些分布会重叠在一起，不容易看。而这种joyplot，有一种山峰叠峦的即视感：&lt;/p&gt;
&lt;p&gt;![](&lt;a href=&#34;https://guangchuangyu.github.io/blog_images/R/ggjoy/Screenshot&#34;&gt;https://guangchuangyu.github.io/blog_images/R/ggjoy/Screenshot&lt;/a&gt; 2017-07-11 16.37.22.png)&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Linux中使用QQ</title>
      <link>https://guangchuangyu.github.io/2017/07/wine-qq/</link>
      <pubDate>Sun, 09 Jul 2017 07:57:46 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/wine-qq/</guid>
      <description>&lt;p&gt;之前在写《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484423&amp;amp;idx=1&amp;amp;sn=311c627bb70e6fc626bb1f014ec0a976&amp;amp;chksm=ec43b540db343c56fb01f86851c0a4b685351b860d0c9ac2f9709857428b4b76b85bf2bc8b49#rd&#34;&gt;开源的macOS和linux版微信&lt;/a&gt;》时，有小伙伴问怎么搞QQ，做为一个上了年纪的人，我已经不怎么用QQ了。&lt;/p&gt;
&lt;p&gt;QQ跑Linux基本上无解，疼讯说好的Linux版死了好多年，现在只有WebQQ可以用。如果你们早生几年，就会遇到Linux上用QQ的好时代。在《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484265&amp;amp;idx=1&amp;amp;sn=7e184d6bf26d2b91485cab0aec3102b8&amp;amp;chksm=ec43b22edb343b38586fa21db0831df49bfe4e0106b22c5c0d93afe16dda88dc1a1a6e5d5248#rd&#34;&gt;十年前截屏&lt;/a&gt;》一文中，我就晒过在Gentoo上跑用Java开发的LumaQQ，在NetBSD上跑用C++开发的Eva，这些都极好用，而且像当年QQ上好友纷纷隐身的时候，LumaQQ推出了如来神掌，你可以看到谁是隐身的，以至于有些Windows用户也去用LumaQQ，那是当年最美好的时代，然而这些都死掉了。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>SCIENCE文章用了DAVID被吐槽</title>
      <link>https://guangchuangyu.github.io/2017/07/david-clusterprofiler/</link>
      <pubDate>Thu, 06 Jul 2017 05:44:27 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/david-clusterprofiler/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/Bioconductor/clusterProfiler/DAVID/science.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;好端端的一篇文章，因为用了DAVID，在PubPeer上就被吐槽了：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>什么？听说你有文章却不知道该往那里投！</title>
      <link>https://guangchuangyu.github.io/2017/07/jane/</link>
      <pubDate>Sun, 02 Jul 2017 02:22:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/jane/</guid>
      <description>以下这些情况是否在你的科研生活中出现，并给你一定的困扰：
 你想投文章，却不知道该投什么杂志？ 你在写文章中，想找一篇相关的文章来引用？ 如果你是Editor，想为文章找审稿人？  这些问题特别是第1点一定给做科研的人带来了困扰，当然首先你得有manuscript（说多了都是泪）。
这时候我们需要一款神器，JANE：Journal/Author Name Estimator， http://jane.biosemantics.org/。你可以用关键字、标题或摘要来搜索，可以搜索作者、文章和期刊。搜索结果按照相似度给出。
文章投什么杂志 拿自己的摘要去搜期刊，可以找到相似的工作都发表在什么杂志上，这对于我该投什么杂志有参考和指导意义。
找相关文章来引用 这时候把要引用的内容拿来搜文章，相关的文章就搜出来了。
找审稿人 拿别人投稿的摘要来搜作者，轻而易举就找到了相关发表类似工作的作者，联系一下是否愿意审稿，方向性很强，节省了大家的时间，也容易找到专业人士来审。
实例 最后用我DOSE的文章摘要做为实例，copy-paste到搜索框，这里我点击搜期刊：
![](https://guangchuangyu.github.io/blog_images/2017/Screenshot 2017-06-21 11.21.36.png)
我自己的文章就搜出来了，然后还有一些相关的文章，也是发表在Bioinformatics上，第二个相似度高的期刊是BMC Bioinformatics，再没有理由说不知道文章该投哪里了吧？！
![](https://guangchuangyu.github.io/blog_images/2017/Screenshot 2017-06-21 11.23.17.png)
 最后的最后，只想问一句，能来个共一吗？</description>
    </item>
    
    <item>
      <title>R的N种打开方式</title>
      <link>https://guangchuangyu.github.io/2017/07/r-gui/</link>
      <pubDate>Sat, 01 Jul 2017 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/07/r-gui/</guid>
      <description>&lt;p&gt;RStudio太成功，以至于有些新手只知有RStudio，不知有R。在&lt;a href=&#34;https://guangchuangyu.github.io/2015/11/r-kernel-in-jupyter-notebook-3/&#34;&gt;R kernel in Jupyter notebook 3&lt;/a&gt;和&lt;a href=&#34;https://guangchuangyu.github.io/2014/12/auto-complete-in-ess/&#34;&gt;auto-complete in ESS&lt;/a&gt;两篇文章中，我介绍了在Jupyter和Emacs里使用R。&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/screenshots/Screenshot%202015-11-04%2010.54.29.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggplot2分面之像素艺术</title>
      <link>https://guangchuangyu.github.io/2017/06/turkey_facet/</link>
      <pubDate>Fri, 30 Jun 2017 09:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/06/turkey_facet/</guid>
      <description>&lt;p&gt;《&lt;a href=&#34;https://guangchuangyu.github.io/cn/2017/06/geofacet/&#34;&gt;按地理位置分面&lt;/a&gt;》这篇文章中，最后我故意把美国地图拖成心型，我知道你们没看懂，大家用一样的软件，有些人只会照着文档来，有些人却能够超越文档，做出作者都没想到的事情。像这个心型排版的美国各州，诚然是没有什么意义的，可以说是瞎扯蛋了，但这里我其实隐藏了一个我想表达但没说出来的信息，抛开地理信息，这个包可以很好玩，我想这一点，可能连作者也没想到，因为作者说了他的想法来自于statebins包，他一心想要做地理位置分面。&lt;/p&gt;
&lt;hr&gt;
&lt;p&gt;然而看到这个心型，难道你在感觉瞎搞的时候，心中没闪过一个念头？这玩意可以瞎搞！瞎搞！瞎搞啊！&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>一大波ggtree贴纸来袭</title>
      <link>https://guangchuangyu.github.io/2017/06/ggtree_sticker/</link>
      <pubDate>Wed, 28 Jun 2017 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/06/ggtree_sticker/</guid>
      <description>&lt;p&gt;还记得《&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247483679&amp;amp;idx=1&amp;amp;sn=e9038cdaeb776355becba5ccfa01b501&amp;amp;chksm=ec43b058db34394ed7afc20c246e1b664fe3b1d54e07b7c92b26bfcf292a46879926a4697a5a&amp;amp;scene=21#wechat_redirect&#34;&gt;ggtree hex sticker&lt;/a&gt;》一文吧？画了几个六角贴，纯代码生成。时隔半年，原来的ggtree已经分成了&lt;code&gt;treeio&lt;/code&gt;和&lt;code&gt;ggtree&lt;/code&gt;两个包，而我也做了这两个包的六角贴，终于我花了289美元印了一大波贴纸+磁贴。&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/R/hexSticker/WechatIMG12.jpeg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>pixel art of ggplot2 faceting using geofacet</title>
      <link>https://guangchuangyu.github.io/2017/06/pixel-art-geofacet/</link>
      <pubDate>Mon, 26 Jun 2017 20:13:35 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/06/pixel-art-geofacet/</guid>
      <description>&lt;p&gt;I just discovered an interesting &lt;code&gt;ggplot2&lt;/code&gt; extension, &lt;code&gt;geofacet&lt;/code&gt;, that supports arranging facet panels that mimics geographic topoloty.&lt;/p&gt;
&lt;p&gt;After playing with it, I realized that it is not only for visualizing &lt;code&gt;geo&lt;/code&gt;-related data, but also can be fun for presenting data to mimics pixel art.&lt;/p&gt;
&lt;p&gt;![](&lt;a href=&#34;https://guangchuangyu.github.io/blog_images/2017/Screenshot&#34;&gt;https://guangchuangyu.github.io/blog_images/2017/Screenshot&lt;/a&gt; 2017-06-26 15.49.50.png)&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>按地理位置进行分面</title>
      <link>https://guangchuangyu.github.io/2017/06/geofacet/</link>
      <pubDate>Mon, 26 Jun 2017 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/06/geofacet/</guid>
      <description>&lt;p&gt;CRAN刚上线的新包&lt;code&gt;geofacet&lt;/code&gt;，可以让ggplot2分面按指定的地理位置来，比如下面的数据，美国各州各项指标的排名：&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;  &lt;span style=&#34;color:#a6e22e&#34;&gt;head&lt;/span&gt;(state_ranks)
    state   name   variable rank
&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;    AK Alaska  education   &lt;span style=&#34;color:#ae81ff&#34;&gt;28&lt;/span&gt;
&lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;    AK Alaska employment   &lt;span style=&#34;color:#ae81ff&#34;&gt;50&lt;/span&gt;
&lt;span style=&#34;color:#ae81ff&#34;&gt;3&lt;/span&gt;    AK Alaska     health   &lt;span style=&#34;color:#ae81ff&#34;&gt;25&lt;/span&gt;
&lt;span style=&#34;color:#ae81ff&#34;&gt;4&lt;/span&gt;    AK Alaska     wealth    &lt;span style=&#34;color:#ae81ff&#34;&gt;5&lt;/span&gt;
&lt;span style=&#34;color:#ae81ff&#34;&gt;5&lt;/span&gt;    AK Alaska      sleep   &lt;span style=&#34;color:#ae81ff&#34;&gt;27&lt;/span&gt;
&lt;span style=&#34;color:#ae81ff&#34;&gt;6&lt;/span&gt;    AK Alaska    insured   &lt;span style=&#34;color:#ae81ff&#34;&gt;50&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;我们正常画图是这样子的：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Linux装windows的二逼</title>
      <link>https://guangchuangyu.github.io/2017/06/lxde-theme/</link>
      <pubDate>Mon, 19 Jun 2017 07:57:46 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/06/lxde-theme/</guid>
      <description>&lt;p&gt;做为一个上了年纪的人，显然已经离不开微信了，macOS还好，企鹅还有照顾到，但linux难道就只能用web版吗？显然不应该的。&lt;/p&gt;
&lt;p&gt;如果你是Arch Linux用户的话，那么aur源里已经有好几个款式可以选了：&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt; ygc  ~  yaourt -Ss wechat
aur/electronic-wechat 2.0-2 &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;8&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;1.29&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;
    A better WeChat client
aur/electronic-wechat-bin 2.0-1 &lt;span style=&#34;color:#f92672&#34;&gt;[&lt;/span&gt;installed&lt;span style=&#34;color:#f92672&#34;&gt;]&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;3&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;0.36&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;
    A better WeChat on macOS and Linux. Built with Electron by Zhongyi Tong.
aur/electronic-wechat-git 1.4.0.43.gb18ff6d-1 &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;6&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;0.00&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;
    An Electron application &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; WeChat
aur/franz-bin 4.0.4-5 &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;86&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;12.73&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;
    Franz is a free messaging app / former Emperor of Austria and combines 
    chat &amp;amp; messaging services into one application. Franz currently supports 
    Slack, WhatsApp, WeChat, HipChat, Facebook Messenger, Telegram, Google 
    Hangouts, GroupMe, Skype and many more.
aur/wechat-web-devtools-git 0.17.171900-1 &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;1&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;0.78&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;
    Wechat Web Developer Tools
aur/wechatircd-git r85.bb8f354-1 &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;0&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;0.00&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;
    IRC server capable of controlling Web WeChat
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;这里我要介绍的是electronic-wechat。我比较懒，用下面的代码，安装二进制版：&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;yaourt -S electronic-wechat-bin
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>纯文本可视化FASTQ质量数据</title>
      <link>https://guangchuangyu.github.io/2017/06/quality_bar_fastq/</link>
      <pubDate>Tue, 06 Jun 2017 07:57:46 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/06/quality_bar_fastq/</guid>
      <description>&lt;p&gt;![](&lt;a href=&#34;https://guangchuangyu.github.io/blog_images/2017/Screenshot&#34;&gt;https://guangchuangyu.github.io/blog_images/2017/Screenshot&lt;/a&gt; 2017-06-02 14.15.14.png)&lt;/p&gt;
&lt;p&gt;一早曾老师就来发github repo，虽然有意思，但在我看来就是乱用emoji，用一个人类不可读（你怎么能够记住表情如何与数值对应上？！）来表示另一个人类不友好（质量编码）的数据，这绝对不是个好主意。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>怀疑人生！我没欠你们钱，好吗？</title>
      <link>https://guangchuangyu.github.io/2017/05/xiaomiquan/</link>
      <pubDate>Tue, 30 May 2017 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/05/xiaomiquan/</guid>
      <description>&lt;p&gt;写了十几年的博客，虽然好早之前就发现一些博客文被《生信人》公众号抄了，但一直不愿意开公众号，去年年底尝试开个公众号，原创保护不给别人抄倒不是主要，而是我感觉到公众号已经绑架了中国人的阅读入口，可以尝试把博客文搬上来，这样大家可以在微信里搜到文章，有利于传播嘛。而我不是单纯为传播知识而来，而主要是推送我自己的东西，这在《为什么要开这个公众号》一文中已经讲了，维护我写的几个软件，花掉大量的时间，现在给我发邮件问问题，我基本都会让他们去biostars或bioconductor论坛上去问，公开交流有利于别的用户参与/学习，有助于减少重复解答，我也不断完善文档，很多问题其实在文档里都有答案，但人的天性就是懒、不愿学习（我在ggtree发布的第一篇文章里也提及了这点，说了%&amp;lt;+%操作符就是给懒人用的）。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>开源的macOS和linux版微信</title>
      <link>https://guangchuangyu.github.io/2017/05/electronic_wechat/</link>
      <pubDate>Mon, 29 May 2017 07:57:46 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/05/electronic_wechat/</guid>
      <description>在开源的macOS和linux版微信一文中，观众想知道怎么装windows，应你们的需求，来一发。
见过我2007年以前截屏的话，都会发现gnome和kde没出现过，我喜欢轻量的wm和软件，当年xfce出来的时候，号称轻量，其实也是中级以上，gnome2本身很轻量(gnome3我就不知道了），它给人重量都怪nautilus太慢。后来出现了lxde，才是符合我标准的集易用与轻量一身的桌面，lxde轻量到什么程度？能跑win98的电脑都可以流畅跑lxde！
LXDE本身就像极了windows经典桌面，而windows界面，大家（起码我是）最爱的还是经典界面，windows 2000是最高水平！虽然土灰土灰的，谁用谁知道，如果长时间盯屏幕，这种土灰土灰的界面，眼睛最不容易累！
LXDE因为本身菜单和自带的软件，都对windows用户极其友好，所以其实已经很像了。如果你想它再像一点，你可以把图标搞成windows的，比如archlinux的aur源里就有windows 95的图标，这逼就装得有点过了。
$ yaourt -Ss classic95 aur/classic95-icons 1-1 [installed] (3) (0.09) Classic icon set from Windows 95 再者就是gtk主题，自带的Redmond，就是windows经典的土灰，最后就是开始菜单，你只要找一个windows开始菜单按纽的图片，大功告成。
就是这么简单!
 要想装win7，win8这样比较现代化的界面，我推荐一个主题包: https://github.com/nhermosilla14/WinAte，自带win7、win8主题，桌面壁纸、鼠标主题、图标等。
而且这个主题包还附送了各大系统的logo，也就是开始菜单的图标，你可以装成别的系统，请随便装：</description>
    </item>
    
    <item>
      <title>emojifont公众号文章</title>
      <link>https://guangchuangyu.github.io/2017/05/emojifont%E5%85%AC%E4%BC%97%E5%8F%B7%E6%96%87%E7%AB%A0/</link>
      <pubDate>Sun, 28 May 2017 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/05/emojifont%E5%85%AC%E4%BC%97%E5%8F%B7%E6%96%87%E7%AB%A0/</guid>
      <description>&lt;p&gt;最近看一个画图的公众号，基本上通篇是代码，最后上个图，我觉得作者就只想表达「哇，我好牛逼」，读者看完可能也只是发出一句「好牛逼」，然后就没有然后了。且不说他读的数据是他电脑上的，你拿了代码也不好重复，最主要是代码死长，缺少解释！&lt;/p&gt;
&lt;p&gt;我的写作风格则不一样，一篇文章我一般只会讲解一个点，力图讲清楚，让别人看明白。比如&lt;a href=&#34;http://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484186&amp;amp;idx=1&amp;amp;sn=d41ee81398a8c18d07e3b1ffe680d521&amp;amp;chksm=ec43b25ddb343b4b87254521c6c134513a3b3535d28064d2bf71d37f9183948895056151c8d0&amp;amp;scene=21#wechat_redirect&#34;&gt;bootstrap分段标记&lt;/a&gt;这一篇，代码足够短且简单，但我还是分模块来讲，一行画树，一行做bootstrap分段标记，最后一行修图，虽然三行，但按功能分开，再加上文字解释，读懂是必须的。再比如&lt;a href=&#34;http://mp.weixin.qq.com/s?__biz=MzI5NjUyNzkxMg==&amp;amp;mid=2247484095&amp;amp;idx=1&amp;amp;sn=e98fb2e95cd7d2775a5611ab076fdeb5&amp;amp;chksm=ec43b3f8db343aee763e85b21b4fcf26b36049f0ea48066d65f86ee9895073d0c8e010f4a7ee&amp;amp;scene=21#wechat_redirect&#34;&gt;纯代码生成banner​&lt;/a&gt;也是分成加载中文字体、读图、图上嵌图三块。即使简单的代码，也要分模块配以文字解析。&lt;/p&gt;
&lt;p&gt;我每次只讲解一个点，但有些知识点是关联的，所以有可能会有断片的情况出现，比如之前写phylomoji，就有同学表示没看懂，这个用到了ggtree和emojifont，两个包我都写过很多文介绍，所以在写phylomoji时都没有介绍，如果没看过以前文章的人，可能就不清楚了。所以呢，适当的时候，汇总一下，是很有必要的。&lt;/p&gt;
&lt;p&gt;emojifont包我基本上都介绍完了，如果你能通读这几篇文章，那么你必然能够用emoji来作图装逼，能够用emoji来娱乐自己，就像我用emoji给自己快乐一样！&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>viziometric</title>
      <link>https://guangchuangyu.github.io/2017/05/viziometric/</link>
      <pubDate>Sat, 20 May 2017 10:40:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/05/viziometric/</guid>
      <description>&lt;p&gt;收到了&lt;a href=&#34;http://viziometrics.org&#34;&gt;Viziometric&lt;/a&gt;的邮件：&lt;/p&gt;
&lt;p&gt;![](&lt;a href=&#34;https://guangchuangyu.github.io/blog_images/screenshots/VizioMetric/Screenshot&#34;&gt;https://guangchuangyu.github.io/blog_images/screenshots/VizioMetric/Screenshot&lt;/a&gt; 2017-05-19 19.48.20.png)&lt;/p&gt;
&lt;p&gt;说要我给自己的一篇文章选一张图做为代表，我顺手点开，没想到这是一款神器啊！这是由University of Washington做Computer Vision的研究生做的一个&lt;strong&gt;学术图片&lt;/strong&gt;搜索引擎，去年被Economist和MIT Technology报道过。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>[Bioc 3.5] NEWS of my BioC packages</title>
      <link>https://guangchuangyu.github.io/2017/05/bioc-3.5-news-of-my-bioc-packages/</link>
      <pubDate>Fri, 19 May 2017 18:13:57 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/05/bioc-3.5-news-of-my-bioc-packages/</guid>
      <description>&lt;p&gt;I have 8 packages published within the &lt;code&gt;Bioconductor&lt;/code&gt; project.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/ChIPseeker&#34;&gt;ChIPseeker&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/clusterProfiler&#34;&gt;clusterProfiler&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/DOSE&#34;&gt;DOSE&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/ggtree&#34;&gt;ggtree&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/GOSemSim&#34;&gt;GOSemSim&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/meshes&#34;&gt;meshes&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/ReactomePA&#34;&gt;ReactomePA&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/treeio&#34;&gt;treeio&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;A new package &lt;a href=&#34;http://guangchuangyu.github.io/treeio&#34;&gt;treeio&lt;/a&gt; was included in BioC 3.5 release.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Phylomoji with ggtree and emojifont</title>
      <link>https://guangchuangyu.github.io/2017/05/phylomoji-with-ggtree-and-emojifont/</link>
      <pubDate>Wed, 17 May 2017 11:11:11 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/05/phylomoji-with-ggtree-and-emojifont/</guid>
      <description>&lt;p&gt;With ggtree (Yu et al. 2017), it is very easy to create phylomoji. Emoji is internally supported by ggtree.&lt;/p&gt;
&lt;h2 id=&#34;use-emoji-in-taxa-labels&#34;&gt;Use emoji in taxa labels&lt;/h2&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code class=&#34;language-{r}&#34; data-lang=&#34;{r}&#34;&gt;library(ggtree)
tree_text &amp;lt;- &amp;quot;(((((cow, (whale, dolphin)), (pig2, boar)), camel), fish), seedling);&amp;quot;
x &amp;lt;- read.tree(text=tree_text)
ggtree(x, linetype=&amp;quot;dashed&amp;quot;, color=&#39;firebrick&#39;) +
    xlim(NA, 7) + ylim(NA, 8.5) +
    geom_tiplab(aes(color=label), parse=&#39;emoji&#39;, size=14, vjust=0.25) +
    labs(title=&amp;quot;phylomoji&amp;quot;, caption=&amp;quot;powered by ggtree + emojifont&amp;quot;)
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/R/emojifont/phylomoji_files/figure-markdown_github/unnamed-chunk-2-1.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>enrichDAVID支持自定义背景</title>
      <link>https://guangchuangyu.github.io/2017/05/enrichdavid-user-bg/</link>
      <pubDate>Tue, 16 May 2017 07:04:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/05/enrichdavid-user-bg/</guid>
      <description>&lt;p&gt;虽然我不喜欢DAVID，但很多用户喜欢，所以clusterProfiler也支持了，最近github上又有人&lt;a href=&#34;https://github.com/GuangchuangYu/clusterProfiler/issues/87&#34;&gt;要求支持自定义背景&lt;/a&gt;。&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Dear Guangchuang,&lt;/p&gt;
&lt;p&gt;I am using clusterProfiler in Kegg pathway enrichment analysis, it is useful and nice. I am looking for a function which accept background and has ability to deal with Ensembl gene ID.&lt;/p&gt;
&lt;p&gt;In a function enrichDAVID it can takes ensembl gene id as an input format, but not allows to enter background.
&lt;code&gt;enrichDAVID(gene = gene, idType=&amp;quot;ENSEMBL_GENE_ID&amp;quot;, annotation=&amp;quot;KEGG_PATHWAY&amp;quot;, species= &amp;quot;hsa&amp;quot;)&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;Other command enrichKEGG has a background input but only takes entrez gene id,
&lt;code&gt;enrichKEGG(gene, organism = &amp;quot;hsa&amp;quot;, keyType = &amp;quot;kegg&amp;quot;, universe)&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;I have tried to convert my ensembl gene IDs to entrez gene id, but some ensembl gene IDs represent more than one entrez gene ID. 
I downloaded KEGG pathway dataset to apply fisher exact test. however, genes are in entrez ID and i am still dont know how to convert.&lt;/p&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>bootstrap value分段标记</title>
      <link>https://guangchuangyu.github.io/2017/05/bootstrap-value%E5%88%86%E6%AE%B5%E6%A0%87%E8%AE%B0/</link>
      <pubDate>Wed, 10 May 2017 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/05/bootstrap-value%E5%88%86%E6%AE%B5%E6%A0%87%E8%AE%B0/</guid>
      <description>&lt;p&gt;想要分段标记bootstrap，比如&lt;code&gt;0-70&lt;/code&gt;, &lt;code&gt;70-90&lt;/code&gt;, &lt;code&gt;90-100&lt;/code&gt;之类的。这个对于ggtree来说，太简单。&lt;/p&gt;
&lt;p&gt;首先我们要读树，用&lt;code&gt;treeio&lt;/code&gt;的&lt;code&gt;read.newick&lt;/code&gt;，它和&lt;code&gt;read.tree&lt;/code&gt;的不同之处是，加入了参数&lt;code&gt;node.label&lt;/code&gt;，当&lt;code&gt;node.label&lt;/code&gt;存的不是&lt;code&gt;label&lt;/code&gt;，而是&lt;code&gt;bootstrap&lt;/code&gt;等数字型的时候，你可以传入&lt;code&gt;node.label=&#39;support&#39;&lt;/code&gt;，这样它会把node label解析为support value，另存为树注释数据，而不是和tip label混在一起。label变量只能存为字符型，因为和tip label混了，而字符型会让数字操作稍微复杂点。所以我们要用&lt;code&gt;read.newick&lt;/code&gt;。&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;tree &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;read.newick&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;RMI.phy_phyml_tree_rooted_labeled.txt&amp;#34;&lt;/span&gt;, node.label&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;support&amp;#39;&lt;/span&gt;)
root &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;getRoot&lt;/span&gt;(tree&lt;span style=&#34;color:#f92672&#34;&gt;@&lt;/span&gt;phylo)

p &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;ggtree&lt;/span&gt;(tree, color&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;black&amp;#34;&lt;/span&gt;, size&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;1.5&lt;/span&gt;, linetype&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;,  ladderize&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;TRUE&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
     &lt;span style=&#34;color:#a6e22e&#34;&gt;ggtitle&lt;/span&gt;(label&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Figure A&amp;#34;&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; 
    &lt;span style=&#34;color:#a6e22e&#34;&gt;geom_tiplab&lt;/span&gt;(size&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#ae81ff&#34;&gt;4.5&lt;/span&gt;, hjust &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;-0.060&lt;/span&gt;, fontface&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;bold&amp;#34;&lt;/span&gt;) &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt;  &lt;span style=&#34;color:#a6e22e&#34;&gt;xlim&lt;/span&gt;(&lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;, &lt;span style=&#34;color:#ae81ff&#34;&gt;0.09&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>annotate tree with user specific data</title>
      <link>https://guangchuangyu.github.io/2017/04/annotate-tree-with-user-specific-data/</link>
      <pubDate>Sat, 29 Apr 2017 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/04/annotate-tree-with-user-specific-data/</guid>
      <description>&lt;p&gt;![](&lt;a href=&#34;https://guangchuangyu.github.io/blog_images/Bioconductor/ggtree/Screen&#34;&gt;https://guangchuangyu.github.io/blog_images/Bioconductor/ggtree/Screen&lt;/a&gt; Shot 2017-04-29 at 1.46.28 PM.png)&lt;/p&gt;
&lt;p&gt;最新的一个问题，大致讲他有两个trait, A和B，想拿A来给label上色，B来画热图。&lt;/p&gt;
&lt;p&gt;加载用户数据我们有&lt;code&gt;%&amp;lt;+%&lt;/code&gt;操作符，热图有&lt;code&gt;gheatmap&lt;/code&gt;函数。&lt;/p&gt;
&lt;p&gt;我给了他一个简单的例子：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>公号狗的福音</title>
      <link>https://guangchuangyu.github.io/2017/04/%E5%85%AC%E5%8F%B7%E7%8B%97%E7%9A%84%E7%A6%8F%E9%9F%B3/</link>
      <pubDate>Sun, 23 Apr 2017 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/04/%E5%85%AC%E5%8F%B7%E7%8B%97%E7%9A%84%E7%A6%8F%E9%9F%B3/</guid>
      <description>&lt;p&gt;苹果和企鹅分赃没谈好，反正林子大了，就不顾小鸟的死活！取消了iOS的赞赏功能，一个个觉得错过了一个亿，我真不知道原来你们的赞赏有这么多！我半年来得到的还不够我的日薪多。虽然少得可怜，但我还是及时地在当天给出方案来吸引眼球，创作了一个绿色的赞赏按纽。&lt;/p&gt;
&lt;p&gt;我的文章排版都是&lt;a href=&#34;https://guangchuangyu.github.io/cn/2017/01/%E5%BE%AE%E4%BF%A1%E5%85%AC%E4%BC%97%E6%96%87markdown%E4%B8%80%E9%94%AE%E6%8E%92%E7%89%88/&#34;&gt;markdown&lt;/a&gt;，markdown是外部驱动的，要什么效果，CSS话事。这个赞赏按纽无非是个链接，赞赏二字链接到转帐二维码，而要实现按纽的效果，可以专门定义一个style来实现。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>realvnc：各种设备互联</title>
      <link>https://guangchuangyu.github.io/2017/04/realvnc/</link>
      <pubDate>Fri, 14 Apr 2017 13:44:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/04/realvnc/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Virtual Network Computing (VNC) is a special way to remotely control a computer. Like Secure Shell (SSH), a computer user can login to a remote machine on the network and execute commands and access files on the system. However, VNC displays the remote system&amp;rsquo;s desktop while SSH displays a terminal shell. It may be beneficial to learn more about VNC and similar technologies.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/2017/2017-04-13-011729_1280x800_scrot.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>来自R的桌面提醒</title>
      <link>https://guangchuangyu.github.io/2017/04/%E6%9D%A5%E8%87%AAr%E7%9A%84%E6%A1%8C%E9%9D%A2%E6%8F%90%E9%86%92/</link>
      <pubDate>Tue, 11 Apr 2017 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/04/%E6%9D%A5%E8%87%AAr%E7%9A%84%E6%A1%8C%E9%9D%A2%E6%8F%90%E9%86%92/</guid>
      <description>&lt;p&gt;&lt;strong&gt;notifier&lt;/strong&gt;包实现了跨平台的桌面提醒功能，当然它是调用了外部的命令，比如windows使用了&lt;strong&gt;toaster&lt;/strong&gt;，老版本windows使用的是&lt;strong&gt;notifu&lt;/strong&gt;，在linux下使用&lt;strong&gt;notify-send&lt;/strong&gt;，而在OSX下，则调用了&lt;strong&gt;terminal-notifier&lt;/strong&gt;，通过了简单的封装之后，就可以给桌面发布消息提醒了。&lt;/p&gt;
&lt;p&gt;比如：&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;library&lt;/span&gt;(notifier)
&lt;span style=&#34;color:#a6e22e&#34;&gt;notify&lt;/span&gt;(
  title &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;15 Packages out of date&amp;#34;&lt;/span&gt;,
  msg &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;c&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;You can run update.packages() to update them.&amp;#34;&lt;/span&gt;,
  &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;Outdated packages: Boom colorspace desc memuse networkD3&amp;#34;&lt;/span&gt;,
  &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;pbapply revealjs rgl rmdformats timevis and 5 more&amp;#34;&lt;/span&gt;)
)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;​
效果如下：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggimage：ggplot2中愉快地使用图片</title>
      <link>https://guangchuangyu.github.io/2017/04/ggimage/</link>
      <pubDate>Tue, 11 Apr 2017 10:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/04/ggimage/</guid>
      <description>&lt;h1 id=&#34;导言&#34;&gt;导言&lt;/h1&gt;
&lt;p&gt;本文介绍了&lt;strong&gt;ggimage&lt;/strong&gt;包，允许在&lt;strong&gt;ggplot2&lt;/strong&gt;作图时嵌入图片，并支持&lt;code&gt;aes&lt;/code&gt;映射，可以把离散型变量映射到不同图片。目前有几个包可以使用图片嵌入做图，但都是针对特定的场景，这里使用&lt;strong&gt;ggimage&lt;/strong&gt;来展示在这些特定领域里的应用，&lt;strong&gt;ggimage&lt;/strong&gt;的设计是通用的，并不被特定场景所限定，文末又介绍了用R图标来画出R、用饼图来画气泡图等实例。&lt;/p&gt;
&lt;h1 id=&#34;图上嵌图片&#34;&gt;图上嵌图片&lt;/h1&gt;
&lt;p&gt;R 基础图形库（base graphics）可以在做图的时候嵌入图片，使用的是&lt;code&gt;graphics::rasterImage&lt;/code&gt;：&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;imgurl &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;http://phylopic.org/assets/images/submissions/295cd9f7-eef2-441e-ba7e-40c772ca7611.256.png&amp;#34;&lt;/span&gt;
&lt;span style=&#34;color:#a6e22e&#34;&gt;library&lt;/span&gt;(EBImage)
x &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;readImage&lt;/span&gt;(imgurl)
&lt;span style=&#34;color:#a6e22e&#34;&gt;plot&lt;/span&gt;(&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;, type &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;n&amp;#34;&lt;/span&gt;, xlab &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;, ylab &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;, xlim &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;c&lt;/span&gt;(&lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;, &lt;span style=&#34;color:#ae81ff&#34;&gt;8&lt;/span&gt;), ylim &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;c&lt;/span&gt;(&lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;, &lt;span style=&#34;color:#ae81ff&#34;&gt;8&lt;/span&gt;))
&lt;span style=&#34;color:#a6e22e&#34;&gt;rasterImage&lt;/span&gt;(x, &lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;, &lt;span style=&#34;color:#ae81ff&#34;&gt;2&lt;/span&gt;, &lt;span style=&#34;color:#ae81ff&#34;&gt;6&lt;/span&gt;, &lt;span style=&#34;color:#ae81ff&#34;&gt;4&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;img src=&#34;https://raw.githubusercontent.com/Lchiffon/ggimage-md-for-COS/master/figures/raster.png&#34; alt=&#34;R绘图嵌入图片演示&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>generate biobabble banner using ggimage</title>
      <link>https://guangchuangyu.github.io/2017/04/generate-biobabble-banner-using-ggimage/</link>
      <pubDate>Wed, 05 Apr 2017 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/04/generate-biobabble-banner-using-ggimage/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/biobabble_banner.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;制作了一个banner，用来插入到文后，方便阅读到最后的时候，直接扫描关注。&lt;/p&gt;
&lt;p&gt;这图当然用PS一下就可以得到，无非是拼图和加点文字。但做为天天写代码画图的人来说，必然是要纯代码来产生的，而且做科学的人，讲究自动化、可重复性。&lt;/p&gt;
&lt;p&gt;就像有些人不理解data scentist为什么讨厌excel一样，觉得无非是工具，没什么好搞阵营的。试想一下，一个分析流程中间有一步要用到excel，需要人工去点点鼠标，这对于讲究自动化、可重复性的data scientist来说是不可接受的。&lt;/p&gt;
&lt;h2 id=&#34;加载中文字体&#34;&gt;加载中文字体&lt;/h2&gt;
&lt;p&gt;为了打几个中文字，需要先加载字体，这里我用showtext。&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;require&lt;/span&gt;(showtext)
&lt;span style=&#34;color:#a6e22e&#34;&gt;font.add&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;heiti&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;/Library/Fonts/华文黑体.ttf&amp;#34;&lt;/span&gt;)
&lt;span style=&#34;color:#a6e22e&#34;&gt;showtext.auto&lt;/span&gt;()
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>ggplot2字体溢出的那点破事</title>
      <link>https://guangchuangyu.github.io/2017/04/ggplot2-overflow/</link>
      <pubDate>Mon, 03 Apr 2017 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/04/ggplot2-overflow/</guid>
      <description>&lt;p&gt;比如下面的代码：&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;require(ggplot2)
d &amp;lt;- data.frame(x=c(0, 0.002, 0.00575), y = 1:3)
p &amp;lt;- ggplot(d, aes(x, y)) + geom_point() + xlab(NULL) + ylab(NULL)
print(p)
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/Bioconductor/ggtree/geom_text_files/figure-markdown_strict/unnamed-chunk-1-1.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;上面图中x轴的文本&lt;strong&gt;0.006&lt;/strong&gt;，这个数字中的&lt;strong&gt;6&lt;/strong&gt;几乎看不到，因为一半过界了。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>关于ChIPseq注释的几个问题</title>
      <link>https://guangchuangyu.github.io/2017/03/%E5%85%B3%E4%BA%8Echipseq%E6%B3%A8%E9%87%8A%E7%9A%84%E5%87%A0%E4%B8%AA%E9%97%AE%E9%A2%98/</link>
      <pubDate>Fri, 31 Mar 2017 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/03/%E5%85%B3%E4%BA%8Echipseq%E6%B3%A8%E9%87%8A%E7%9A%84%E5%87%A0%E4%B8%AA%E9%97%AE%E9%A2%98/</guid>
      <description>&lt;h2 id=&#34;为什么我要用某个基因组版本&#34;&gt;为什么我要用某个基因组版本？&lt;/h2&gt;
&lt;p&gt;在上一篇文章中，我用了&lt;code&gt;TxDb.Hsapiens.UCSC.hg19.knownGene&lt;/code&gt;。 &lt;strong&gt;hg19&lt;/strong&gt;的&lt;strong&gt;TxDb&lt;/strong&gt;, 或者有人就要问了，为什么不用&lt;strong&gt;hg38&lt;/strong&gt;？&lt;/p&gt;
&lt;p&gt;这个问题，不是说要用那一个，不能用那一个。而是你必须得用某一个，这取决于你最初&lt;strong&gt;fastq&lt;/strong&gt;用BWA/Bowtie2比对于某个版本的基因组，你最初用了某个版本，后面就得用相应的版本，不能混，因为不同版本的位置信息有所不同。&lt;/p&gt;
&lt;p&gt;当然如果要（贵圈喜欢的）强搞，也不是不可以，你得有chain file，先跑个liftOver，实际上就是在两个基因组版本之间做了位置转换。&lt;/p&gt;
&lt;h2 id=&#34;为什么说chipseeker支持所有物种&#34;&gt;为什么说&lt;strong&gt;ChIPseeker&lt;/strong&gt;支持所有物种？&lt;/h2&gt;
&lt;p&gt;背景注释信息用了&lt;strong&gt;TxDb&lt;/strong&gt;就能保证所有物种都支持了？我去哪里找我要的&lt;strong&gt;TxDb&lt;/strong&gt;?&lt;/p&gt;
&lt;p&gt;我写&lt;strong&gt;ChIPseeker&lt;/strong&gt;的时候，我做的物种是人，&lt;strong&gt;ChIPseeker&lt;/strong&gt;在线一周就有剑桥大学的人写信跟我说在用&lt;strong&gt;ChIPseeker&lt;/strong&gt;做果蝇，在&lt;a href=&#34;https://guangchuangyu.github.io/cn/2017/03/bed%E6%96%87%E4%BB%B6/&#34;&gt;BED文件&lt;/a&gt;一文中，也提到了最近有人在Biostars上问用&lt;strong&gt;ChIPseeker&lt;/strong&gt;做裂殖酵母。&lt;/p&gt;
&lt;p&gt;首先Bioconductor提供了30个TxDb包，可以供我们使用，这当然只能覆盖到一小部分物种，我们的物种基因组信息，多半要从UCSC或者Ensembl获得，我敢说支持所有物种，就是因为UCSC和ensembl上所有的基因组都可以被&lt;strong&gt;ChIPseeker&lt;/strong&gt;支持。&lt;/p&gt;
&lt;p&gt;因为我们可以使用&lt;strong&gt;GenomicFeatures&lt;/strong&gt;包函数来制作TxDb对象：&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;makeTxDbFromUCSC： 通过UCSC在线制作TxDb&lt;/li&gt;
&lt;li&gt;makeTxDbFromBiomart: 通过ensembl在线制作TxDb&lt;/li&gt;
&lt;li&gt;makeTxDbFromGRanges：通过GRanges对象制作TxDb&lt;/li&gt;
&lt;li&gt;makeTxDbFromGFF：通过解析GFF文件制作TxDb&lt;/li&gt;
&lt;/ul&gt;</description>
    </item>
    
    <item>
      <title>News in emojifont</title>
      <link>https://guangchuangyu.github.io/2017/03/news-in-emojifont/</link>
      <pubDate>Thu, 23 Mar 2017 14:30:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/03/news-in-emojifont/</guid>
      <description>&lt;p&gt;面向对象有多种实现方式，R里面就有3种，class-based, method-based, object-based，R6与C++/JAVA一样是class-based的，S3/S4是method-based的，还有一种是object-based的，这在proto包中实现，很多人可能没听说过，但是ggplot2你们一定听过，ggplot2就是object-based的实现，它现在是自己的定制实现，称之为ggproto。&lt;/p&gt;
&lt;p&gt;emojifont就是用proto实现的，属于我的练手之作，很高兴深受大家的喜欢。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>how to bug author</title>
      <link>https://guangchuangyu.github.io/2017/03/how-to-bug-author/</link>
      <pubDate>Mon, 20 Mar 2017 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/03/how-to-bug-author/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;&lt;a href=&#34;http://blog.devtang.com/2017/03/05/how-to-get-help/&#34;&gt;http://blog.devtang.com/2017/03/05/how-to-get-help/&lt;/a&gt; 这篇文章讲问问题的礼仪，会问问题的人容易得到别人的帮助，并不是作者拽，而是对着一群不会问问题，且一副理所当然的用户，早就有了深深的无力感，也看看我写的这篇吧，&lt;a href=&#34;https://guangchuangyu.github.io/2016/07/how-to-bug-author/&#34;&gt;https://guangchuangyu.github.io/2016/07/how-to-bug-author/&lt;/a&gt;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;这是前几天的文字推送，不知道大家有没有阅读这两篇博客文？如何提问，这是一项重要的技能，很遗憾很多人并没有这项技能！&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/2017/413360782.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;就在上周，我正好就在微信群里跟某位老师说不要给我个截屏，说能不能在ggtree里实现某功能。懂的人知道，我只是希望大家用正确的方式来做事情，不懂的人，当然觉得我拽，JJYY什么的。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>peak注释</title>
      <link>https://guangchuangyu.github.io/2017/03/peak%E6%B3%A8%E9%87%8A/</link>
      <pubDate>Thu, 16 Mar 2017 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/03/peak%E6%B3%A8%E9%87%8A/</guid>
      <description>&lt;p&gt;这一次讲解非常重要的peak注释，注释在&lt;strong&gt;ChIPseeker&lt;/strong&gt;里只需要用到一个函数&lt;strong&gt;annotatePeak&lt;/strong&gt;，它可以满足大家各方面的需求。&lt;/p&gt;
&lt;h2 id=&#34;输入&#34;&gt;输入&lt;/h2&gt;
&lt;p&gt;当然需要我们上次讲到的BED文件，&lt;strong&gt;ChIPseeker&lt;/strong&gt;自带了5个BED文件，用&lt;strong&gt;getSampleFiles()&lt;strong&gt;可以拿到文件的全路径，它返回的是个named list，我这里取第4个文件来演示。&lt;strong&gt;annotatePeak&lt;/strong&gt;的输入也可以是&lt;/strong&gt;GRanges&lt;/strong&gt;对象，你如果用R做peak calling的话,直接就可以衔接上&lt;strong&gt;ChIPseeker&lt;/strong&gt;了。&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;&amp;gt; require(ChIPseeker)
&amp;gt; f = getSampleFiles()[[4]]
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;巧妇难为无米之炊，就像拿到&lt;strong&gt;fastq&lt;/strong&gt;要跑&lt;strong&gt;BWA&lt;/strong&gt;，你需要全基因组的序列一样，做注释当然需要注释信息，基因的起始终止，基因有那些内含子，外显子，以及它们的起始终止，非编码区的位置，功能元件的位置等各种信息。&lt;/p&gt;
&lt;p&gt;很多软件会针对特定的物种去整理这些信息供软件使用，但这样就限制了软件的物种支持，有些开发者写软件本意也是解决自己的问题，可能对自己的研究无关的物种也没兴趣去支持。&lt;/p&gt;
&lt;p&gt;然而&lt;strong&gt;ChIPseeker&lt;/strong&gt;支持所有的物种，你没有看错，&lt;strong&gt;ChIPseeker&lt;/strong&gt;没有物种限制，当然这是有前提的，物种本身起码是有基因的位置这些注释信息，不然就变无米之炊了。&lt;/p&gt;
&lt;p&gt;这里我们需要的是一个&lt;strong&gt;TxDb&lt;/strong&gt;对象，这个&lt;strong&gt;TxDb&lt;/strong&gt;就包含了我们需要的各种信息，&lt;strong&gt;ChIPseeker&lt;/strong&gt;会把信息抽取出来，用于注释时使用。&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;&amp;gt; require(TxDb.Hsapiens.UCSC.hg19.knownGene)
&amp;gt; txdb = TxDb.Hsapiens.UCSC.hg19.knownGene
&amp;gt; x = annotatePeak(f, tssRegion=c(-1000, 1000), TxDb=txdb)
&amp;gt;&amp;gt; loading peak file...				 2017-03-09 11:29:18 PM 
&amp;gt;&amp;gt; preparing features information...		 2017-03-09 11:29:18 PM 
&amp;gt;&amp;gt; identifying nearest features...		 2017-03-09 11:29:19 PM 
&amp;gt;&amp;gt; calculating distance from peak to TSS...	 2017-03-09 11:29:20 PM 
&amp;gt;&amp;gt; assigning genomic annotation...		 2017-03-09 11:29:20 PM 
&amp;gt;&amp;gt; assigning chromosome lengths			 2017-03-09 11:29:42 PM 
&amp;gt;&amp;gt; done...					 2017-03-09 11:29:42 PM 
&lt;/code&gt;&lt;/pre&gt;&lt;blockquote&gt;
&lt;p&gt;这里需要注意的是，启动子区域是没有明确的定义的，所以你可能需要指定&lt;strong&gt;tssRegion&lt;/strong&gt;，把基因起始转录位点的上下游区域来做为启动子区域。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;有了这两个输入（BED文件和TxDb对象），你就可以跑注释了，然后就可以出结果了。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>BED文件</title>
      <link>https://guangchuangyu.github.io/2017/03/bed%E6%96%87%E4%BB%B6/</link>
      <pubDate>Thu, 09 Mar 2017 00:13:57 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/03/bed%E6%96%87%E4%BB%B6/</guid>
      <description>&lt;p&gt;BED的全称是Browser Extensible Data，顾名思义是为genome browser设计的，大名鼎鼎的bedtools可不是什么「床上用品」。&lt;/p&gt;
&lt;p&gt;BED包含有3个必须的字段和9个可选字段。&lt;/p&gt;
&lt;p&gt;三个字段包括：&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;1 chrom - 染色体名字&lt;/li&gt;
&lt;li&gt;2 chromStart - 染色体起始位点&lt;/li&gt;
&lt;li&gt;3 chromEnd - 染色体终止位点&lt;/li&gt;
&lt;/ul&gt;
&lt;blockquote&gt;
&lt;p&gt;这里必须指出的是&lt;strong&gt;chromStart&lt;/strong&gt;是起始于0，而不是1。很多分析软件都忽略
了这一点，会有一个碱基的位移，据我所知Homer和ChIPseeker没有这个问题，而像peakAnalyzer, ChIPpeakAnno等都有位移的问题。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;可选的9个字段包括：&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;4 name - 名字&lt;/li&gt;
&lt;li&gt;5 score - 分值(0-1000), 用于genome browser展示时上色。&lt;/li&gt;
&lt;li&gt;6 strand - 正负链，对于ChIPseq数据来说，&lt;strong&gt;一般&lt;/strong&gt;没有正负链信息。&lt;/li&gt;
&lt;li&gt;7 thickStart - 画矩形的起点&lt;/li&gt;
&lt;li&gt;8 thickEnd - 画矩形的终点&lt;/li&gt;
&lt;li&gt;9 itemRgb - RGB值&lt;/li&gt;
&lt;li&gt;10 blockCount - 子元件（比如外显子）的数目&lt;/li&gt;
&lt;li&gt;11 blockSizes - 子元件的大小&lt;/li&gt;
&lt;li&gt;12 blockStarts - 子元件的起始位点&lt;/li&gt;
&lt;/ul&gt;</description>
    </item>
    
    <item>
      <title>linux版迅雷</title>
      <link>https://guangchuangyu.github.io/2017/03/linux%E7%89%88%E8%BF%85%E9%9B%B7/</link>
      <pubDate>Mon, 06 Mar 2017 23:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/03/linux%E7%89%88%E8%BF%85%E9%9B%B7/</guid>
      <description>&lt;p&gt;上次讲了&lt;a href=&#34;http://guangchuangyu.github.io/2016/03/yet-an-unofficial-bioedit-for-osx/&#34;&gt;OSX版BioEdit&lt;/a&gt;，还蛮受欢迎，说到下载工具，linux的小伙伴们都想用迅雷，有没有？毕竟大家都想耍流氓。许久没打开迅雷，今日一打开，发现被学校给墙掉了。&lt;strong&gt;大写的杯具啊！&lt;/strong&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;You have attempted to use an application which is in violation of your internet usage policy.&lt;/p&gt;
&lt;p&gt;Thunder.Xunlei&lt;/p&gt;
&lt;p&gt;Category: P2P&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;老司机不能偷偷地下片 了，唯有分享出来，带大家上车。还好我有一张半年前的截屏，不然连张图都没有。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>unknown annotation in enrichment analysis</title>
      <link>https://guangchuangyu.github.io/2017/03/unknown-annotation-in-enrichment-analysis/</link>
      <pubDate>Fri, 03 Mar 2017 00:10:37 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/03/unknown-annotation-in-enrichment-analysis/</guid>
      <description>&lt;p&gt;小伙伴说注释不全，比如KEGG只有不到1万个基因有注释，但他一次RNA-seq出来的基因有2万多个，那其它没注释那1万多个岂不是扔了？！就某个通路来说，两种情况，要么属于，要么不属于这个通路。那1万多个应该放在背景里，不要扔。&lt;/p&gt;
&lt;p&gt;我的解答是三种情况，1属于，2不属于，3不知道。对于缺失信息的，当然是扔。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>OSX版BioEdit</title>
      <link>https://guangchuangyu.github.io/2017/02/osx-bioedit/</link>
      <pubDate>Mon, 27 Feb 2017 13:40:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/02/osx-bioedit/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;BioEdit是一个Windows的程序，但在这里我要说的是苹果版！&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;a href=&#34;http://www.mbio.ncsu.edu/bioedit/bioedit.html&#34;&gt;&lt;img src=&#34;http://www.mbio.ncsu.edu/bioedit/Banner1.GIF&#34; alt=&#34;&#34;&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;BioEdit有很多的功能，当然基本上我是不会用的，然而其核心的功能，编辑序列比对，是没法回避的！因为根本找不到可以与之匹敌的软件！&lt;/p&gt;
&lt;p&gt;神马！序列比对不都是clustalw, muscle, mafft这些软件生成完事吗？怎么还要编辑？！我只能说，年轻人，拿衣服啊。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>根据GTF画基因的多个转录本结构</title>
      <link>https://guangchuangyu.github.io/2017/02/%E6%A0%B9%E6%8D%AEgtf%E7%94%BB%E5%9F%BA%E5%9B%A0%E7%9A%84%E5%A4%9A%E4%B8%AA%E8%BD%AC%E5%BD%95%E6%9C%AC%E7%BB%93%E6%9E%84/</link>
      <pubDate>Tue, 21 Feb 2017 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/02/%E6%A0%B9%E6%8D%AEgtf%E7%94%BB%E5%9F%BA%E5%9B%A0%E7%9A%84%E5%A4%9A%E4%B8%AA%E8%BD%AC%E5%BD%95%E6%9C%AC%E7%BB%93%E6%9E%84/</guid>
      <description>&lt;p&gt;这是&lt;a href=&#34;https://mp.weixin.qq.com/s?__biz=MzAxMDkxODM1Ng==&amp;amp;mid=2247484044&amp;amp;idx=2&amp;amp;sn=56b45eaeb4ad344481afa05abeb1c53e&amp;amp;chksm=9b484237ac3fcb219e41d5653fb800f987e7d217bbb3a5a0c0170ffb8e402f4cc5f726212ef7&amp;amp;mpshare=1&amp;amp;scene=1&amp;amp;srcid=0220calgiLgIZmjiiaNXZ0BE&amp;amp;key=df0a0b140e64a33b97880a54ee7cc95794b60a225d5338e88620674bed463405e61c5365394b7830750de8d3a88e122babd535c88c7d74b974b20c509218cf00d106c991a3a3f049c698a8f847aa5e06&amp;amp;ascene=0&amp;amp;uin=MTMxNjc4OTY2Mg%3D%3D&amp;amp;devicetype=iMac14%2C2+OSX+OSX+10.11.6+build&#34;&gt;生物技能树的一道习题&lt;/a&gt;，使用了base plot来画，做为补充，我使用ggplot2来重画一遍。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ChIPseq简介</title>
      <link>https://guangchuangyu.github.io/2017/02/chipseq%E7%AE%80%E4%BB%8B/</link>
      <pubDate>Mon, 20 Feb 2017 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/02/chipseq%E7%AE%80%E4%BB%8B/</guid>
      <description>&lt;p&gt;ChIP是指染色质免疫沉淀，它通过特异结合抗体将DNA结合蛋白免疫沉淀，可以用于捕获蛋白质（如转录因子，组蛋白修饰）的DNA靶点。这技术存在非常久了，在二代测序之前，结合microarray，它的名字叫&lt;code&gt;ChIP-on-chip&lt;/code&gt;，二代测序出来之后，显而易见的，免疫沉淀拉下来的DNA拿去NGS测序，这必然是下一代的ChIP技术，优点也是显而易见的，不再需要设计探针（往往存在着一定的偏向性）。所以NGS出来以后，不差钱的牛逼实验室显然占据上风，谁先做出来，谁就定义了新技术。这是有钱人的竞赛，没钱的只能等着技术烂大街的时候跟风做。&lt;/p&gt;
&lt;p&gt;这是显而易见的下一代技术，外加技术上完全是可行的，所以这是一场单纯的时间竞赛，于是几乎同时出来CNS文章，基本上谁也不比谁差地同时扔出来。&lt;/p&gt;
&lt;blockquote&gt;
&lt;ul&gt;
&lt;li&gt;Johnson DS, Mortazavi A et al. (2007) Genome-wide mapping of in vivo protein–DNA interactions. Science 316: 1497–1502&lt;/li&gt;
&lt;li&gt;Robertson G et al.(2007) Genome-wide profiles of STAT1 DNA association using chromatin immunoprecipitation and massively parallel sequencing. Nature Methods 4: 651–657&lt;/li&gt;
&lt;li&gt;Schmid et al. (2007) ChIP-Seq Data reveal nucleosome architecture of human promoters. Cell 131: 831–832&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;
&lt;p&gt;2007年来自三个不同的实验室，几乎是同时间出来（最长差不了3个月），分别发CNS，一起定义了这个&lt;code&gt;ChIPseq&lt;/code&gt;技术。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>wrapping labels in ggplot2</title>
      <link>https://guangchuangyu.github.io/2017/02/wrapping-labels-in-ggplot2/</link>
      <pubDate>Tue, 14 Feb 2017 09:50:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/02/wrapping-labels-in-ggplot2/</guid>
      <description>&lt;p&gt;在公众号biobabble后台有多人同时在问这个问题：&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/2017/2017-02-12-223832_646x667_scrot.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;晒这个截屏主要想说一点，如果是一两句话就能说清楚的问题，可以提问，如果不是，则不要在后台提问，写邮件或者到论坛提问，是更好的方式，像截屏中显示的，图片显示过期，我根本就没看到过图片。在手机上是无法看的，而我正好几天没在电脑前，于是你们发的图片我看不了，而且我如果没有在24小时之内回复，公众平台就不允许我回复了，因为问题已经过期。所以在此强调，不要在后台发图片提问，不要在后台问稍复杂的问题。&lt;/p&gt;
&lt;p&gt;这个问题其实很简单，用&lt;code&gt;stringr&lt;/code&gt;包的&lt;code&gt;str_wrap&lt;/code&gt;来完成文本自动换行就行了。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggtree发表</title>
      <link>https://guangchuangyu.github.io/2017/01/ggtree%E5%8F%91%E8%A1%A8/</link>
      <pubDate>Sun, 22 Jan 2017 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/01/ggtree%E5%8F%91%E8%A1%A8/</guid>
      <description>&lt;p&gt;MEE在18号出版了今年（第8卷）第1期，ggtree正好在这一期出版，一经出版就有几条推在传播, 我也是在推特上看到，才发现，哦原来我的文章出版了。然后我又发现2017年新鲜出炉有了一篇PNAS的引用。&lt;/p&gt;
&lt;p&gt;我以前没接触过进化，来了现在这个实验室，发现可视化是个大问题，大家都在用AI，慢慢地抠，对于一些和进化树相关的数据，自己一点一点地在AI里面加上去。甚至于genotype table是一个框一个框地在AI里面加的。一方面画一顆树可能用掉你几天的时间，另一方面，太容易出错了，再者你花的时间并不能转化为生产力，每一次你都要这么搞！这简直就是水深火热啊！&lt;/p&gt;
&lt;p&gt;我也帮师兄写过一些代码，给定进化树上节点的序列，我比较父节点和子节点，把碱基或氨基酸替换写到newick树的node label，然后就可以用软件展示序列的替换情况。教会了师兄，他再去给他的师弟师妹们演示，说以后咱们可以这么干了，一个个觉得很牛逼，我内心想的是，愚蠢的人类啊，node label只能存一个信息，牛逼的方式应该是可以展示多个维度的信息，通过图层自由组合。这个时候我就产生了要写ggtree的想法。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>微信公众文markdown一键排版</title>
      <link>https://guangchuangyu.github.io/2017/01/%E5%BE%AE%E4%BF%A1%E5%85%AC%E4%BC%97%E6%96%87markdown%E4%B8%80%E9%94%AE%E6%8E%92%E7%89%88/</link>
      <pubDate>Wed, 18 Jan 2017 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/01/%E5%BE%AE%E4%BF%A1%E5%85%AC%E4%BC%97%E6%96%87markdown%E4%B8%80%E9%94%AE%E6%8E%92%E7%89%88/</guid>
      <description>&lt;p&gt;微信公众号的后台排版功能很差，要想让读者阅读起来舒服，写作的人要花很多时间，于是出现了像&lt;code&gt;秀米&lt;/code&gt;这样的第三方排版网站，即便如此，要想排出好的版面，仍然是件耗时的事情，而且像在文章里贴代码这种小众需求，是不被支持的，代码就像普通文本，那叫一个乱。&lt;/p&gt;
&lt;p&gt;好在微信平台是支持富文本的，我们复制粘贴过来，格式都还会在，像抄我ggplot2那篇文的&lt;code&gt;生信人&lt;/code&gt;，就是完全复制粘贴的，还是我博客上的排版，当然它到了公众号上就乱了，我们其实很容易发现很多复制粘贴的，都没自己排一下版面，直接&lt;code&gt;ctrl-C&lt;/code&gt;, &lt;code&gt;ctrl-V&lt;/code&gt;一点诚意都没有。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>R包辣鸡之CorMut</title>
      <link>https://guangchuangyu.github.io/2017/01/cormut/</link>
      <pubDate>Tue, 17 Jan 2017 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/01/cormut/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;曾经QQ上有人叫我帮忙，跑某个R包做个分析，我一看那包，一堆bug，显然不能用，那就不是简单的事了，我可没空帮他写代码，于是他就经常恶心我，有事没事就来说我写ggtree没意义，不是实质科研，不如跟他做点牛逼的，不如再写个R包干他那事。昨天用马甲在进化群里问画树，我还热心贴个代码给他，说看不懂，我在群里说了，我写个文详细介绍一下。然而他的马甲身份暴露啦，所以今日跳票，我写好的文也不发了，你牛逼就不要用马甲来骗代码呀，ggtree没用你不要用呀，叔就是这么任性😎&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;之前讲过某个R包我一看一堆bug，直接放弃，今天倒是拿出来晒一下，不为别的，我只想说一句，一知半解是很危险的，盲目相信软件也是很危险的。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ChIPseq从入门到放弃</title>
      <link>https://guangchuangyu.github.io/2017/01/chipseq%E4%BB%8E%E5%85%A5%E9%97%A8%E5%88%B0%E6%94%BE%E5%BC%83/</link>
      <pubDate>Sun, 08 Jan 2017 22:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/01/chipseq%E4%BB%8E%E5%85%A5%E9%97%A8%E5%88%B0%E6%94%BE%E5%BC%83/</guid>
      <description>&lt;p&gt;接下来要出一个ChIPseq系列，讲一讲ChIPseq和我的ChIPseeker包，从入门到放弃是我自己的个人写照。我做ChIPseq总共也就3个月的时间，做的事情并不多，在一知半解的情况下写下了ChIPseeker包。&lt;/p&gt;
&lt;p&gt;我当时被要求做ChIPseq分析是为他人做嫁衣，而且是完全白干那种，但做为学生，白干也得干。&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/2017/1487166664.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;当时一开始使用ChIPpeakAnno做注释，但用UCSC genome browser检验结果的时候，发现对不上。在对ChIPpeakAnno包不满意的情况下，开始着手写ChIPseeker，其实在使用ChIPpeakAnno的时候，我就有写代码对结果做一些可视化，所以未有ChIPseeker先有ChIPseeker的部分可视化功能。当时写了篇博客文说ChIPpeakAnno的问题，一个月后就在Bioconductor上发表了ChIPseeker，这包完全是我半夜在宿舍里写出来的。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>convert graphic object to tree object using treeio</title>
      <link>https://guangchuangyu.github.io/2017/01/convert-graphic-object-to-tree-object-using-treeio/</link>
      <pubDate>Tue, 03 Jan 2017 14:58:10 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2017/01/convert-graphic-object-to-tree-object-using-treeio/</guid>
      <description>&lt;p&gt;I have splitted &lt;code&gt;ggtree&lt;/code&gt; to 2 packages, &lt;code&gt;treeio&lt;/code&gt; and &lt;code&gt;ggtree&lt;/code&gt;. Now &lt;code&gt;ggtree&lt;/code&gt; is mainly focus on visualization and annotation, while &lt;code&gt;treeio&lt;/code&gt; focus on parsing and exporting tree files. Here is a welcome message from &lt;code&gt;treeio&lt;/code&gt; that you can convert &lt;code&gt;ggtree&lt;/code&gt; output to tree object which can be exported as newick or nexus file if you want.&lt;/p&gt;
&lt;p&gt;Thanks to &lt;code&gt;ggplot2&lt;/code&gt;, output of &lt;code&gt;ggtree&lt;/code&gt; is actually a &lt;code&gt;ggplot&lt;/code&gt; object. The &lt;code&gt;ggtree&lt;/code&gt; object can be rendered as graph by &lt;code&gt;print&lt;/code&gt; method, but internally it is an object that contains data. &lt;code&gt;treeio&lt;/code&gt; defines &lt;code&gt;as.phylo&lt;/code&gt; and &lt;code&gt;as.treedata&lt;/code&gt; to convert &lt;code&gt;ggtree&lt;/code&gt; object to &lt;code&gt;phylo&lt;/code&gt; or &lt;code&gt;treedata&lt;/code&gt; object.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>dotplot for GSEA result</title>
      <link>https://guangchuangyu.github.io/2016/12/dotplot-for-gsea-result/</link>
      <pubDate>Fri, 30 Dec 2016 12:58:10 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/12/dotplot-for-gsea-result/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/Bioconductor/DOSE/gseaplot.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;For GSEA analysis, we are familar with the above figure which shows the running enrichment score. But for most of the software, it lack of visualization method to summarize the whole enrichment result.&lt;/p&gt;
&lt;p&gt;In &lt;a href=&#34;https://guangchuangyu.github.io/DOSE&#34;&gt;DOSE&lt;/a&gt; (and related tools including &lt;a href=&#34;https://guangchuangyu.github.io/clusterProfiler&#34;&gt;clusterProfiler&lt;/a&gt;, &lt;a href=&#34;https://guangchuangyu.github.io/ReactomePA&#34;&gt;ReactomePA&lt;/a&gt; and &lt;a href=&#34;https://guangchuangyu.github.io/meshes&#34;&gt;meshes&lt;/a&gt;), we provide &lt;code&gt;enrichMap&lt;/code&gt; and &lt;code&gt;cnetplot&lt;/code&gt; to summarize GSEA result.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>add layer to specific panel of facet_plot output</title>
      <link>https://guangchuangyu.github.io/2016/12/add-layer-to-specific-panel-of-facet_plot-output/</link>
      <pubDate>Wed, 28 Dec 2016 20:30:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/12/add-layer-to-specific-panel-of-facet_plot-output/</guid>
      <description>&lt;p&gt;This is a question from &lt;a href=&#34;https://groups.google.com/forum/?utm_medium=email&amp;amp;utm_source=footer#!msg/bioc-ggtree/uPgksYWkwCA/oMtHKW7KEgAJ&#34;&gt;ggtree google group&lt;/a&gt;:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Dear ggtree team,&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;how can I apply a geom_xxx to only one facet panel? For example if i want to get &lt;code&gt;geom_hline(yintersect=1:30)&lt;/code&gt; or a &lt;code&gt;geom_text()&lt;/code&gt; in the dot panel?
I cant see the &lt;code&gt;facet_grid(. ~ var)&lt;/code&gt; function call, so I don&amp;rsquo;t know which subsetting to use. I have already read &lt;a href=&#34;http://stackoverflow.com/questions/29873155/geom-text-and-facets-not-working&#34;&gt;http://stackoverflow.com/questions/29873155/geom-text-and-facets-not-working&lt;/a&gt;&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;  tr &amp;lt;- rtree(30)
  
  d1 &amp;lt;- data.frame(id=tr$tip.label, val=rnorm(30, sd=3))
  p &amp;lt;- ggtree(tr)
  
  p2 &amp;lt;- facet_plot(p, panel=&amp;quot;dot&amp;quot;, data=d1, geom=geom_point, aes(x=val), color=&#39;firebrick&#39;)
  d2 &amp;lt;- data.frame(id=tr$tip.label, value = abs(rnorm(30, mean=100, sd=50)))
  
  p3 &amp;lt;- facet_plot(p2, panel=&#39;bar&#39;, data=d2, geom=geom_segment, aes(x=0, xend=value, y=y, yend=y), size=3, color=&#39;steelblue&#39;) + theme_tree2()
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Thanks!
Andreas&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;If this can be done, we can create even more &lt;a href=&#34;https://guangchuangyu.github.io/2016/12/ggtree-version-of-plottree/&#34;&gt;comprehensive tree plots&lt;/a&gt;.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggtree version of plotTree</title>
      <link>https://guangchuangyu.github.io/2016/12/ggtree-version-of-plottree/</link>
      <pubDate>Sat, 17 Dec 2016 13:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/12/ggtree-version-of-plottree/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://holtlab.net/2015/10/03/plotting-trees-data/&#34;&gt;PLOTTING TREES + DATA&lt;/a&gt; is difficult. &lt;a href=&#34;http://holtlab.net/&#34;&gt;@DrKatHolt&lt;/a&gt; developed &lt;a href=&#34;https://github.com/katholt/plotTree&#34;&gt;plotTree&lt;/a&gt; (R and Python scripts) to visualize associated data with trees, &lt;em&gt;e.g.&lt;/em&gt; heatmap, horizontal bar &lt;em&gt;etc&lt;/em&gt;.&lt;/p&gt;
&lt;p&gt;I reproduced the examples presented in the &lt;a href=&#34;https://github.com/katholt/plotTree&#34;&gt;plotTree&lt;/a&gt; repo using &lt;a href=&#34;https://guangchuangyu.github.io&#34;&gt;ggtree&lt;/a&gt;. Source code is freely available in &lt;a href=&#34;https://github.com/GuangchuangYu/plotTree-ggtree&#34;&gt;https://github.com/GuangchuangYu/plotTree-ggtree&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Here are the outputs produced by &lt;code&gt;ggtree&lt;/code&gt;:&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>clifun:在R里装装逼</title>
      <link>https://guangchuangyu.github.io/2016/12/clifun/</link>
      <pubDate>Tue, 13 Dec 2016 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/12/clifun/</guid>
      <description>&lt;p&gt;天天活在命令行下，需要一些有趣的小命令来调节一下枯燥的生活（其实是需要装装逼）。&lt;/p&gt;
&lt;p&gt;![](&lt;a href=&#34;https://guangchuangyu.github.io/blog_images/R/clifun/Screen&#34;&gt;https://guangchuangyu.github.io/blog_images/R/clifun/Screen&lt;/a&gt; Shot 2016-12-12 at 1.42.00 PM.png)&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Edge coloring with user data</title>
      <link>https://guangchuangyu.github.io/2016/12/edge-coloring-with-user-data/</link>
      <pubDate>Mon, 12 Dec 2016 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/12/edge-coloring-with-user-data/</guid>
      <description>&lt;p&gt;Coloring edges in ggtree is quite easy, as we can map the color to numerical or categorical values via the &lt;code&gt;aes(color=VAR)&lt;/code&gt; syntax. For user&amp;rsquo;s own data, it is also easy as &lt;code&gt;ggtree&lt;/code&gt; provide the &lt;code&gt;%&amp;lt;+%&lt;/code&gt; operator to attach user data.&lt;/p&gt;
&lt;p&gt;But as it seems not so obviously for &lt;code&gt;ggtree&lt;/code&gt; users, see question &lt;a href=&#34;https://groups.google.com/forum/#!topic/bioc-ggtree/4GgivKqVjB8&#34;&gt;1&lt;/a&gt;, &lt;a href=&#34;https://github.com/GuangchuangYu/ggtree/issues/76&#34;&gt;2&lt;/a&gt;, and &lt;a href=&#34;https://github.com/GuangchuangYu/ggtree/issues/105&#34;&gt;3&lt;/a&gt;, I will demonstrate how to color edges using user data here.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>scatterpie for plotting pies on ggplot</title>
      <link>https://guangchuangyu.github.io/2016/12/scatterpie-for-plotting-pies-on-ggplot/</link>
      <pubDate>Wed, 07 Dec 2016 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/12/scatterpie-for-plotting-pies-on-ggplot/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/R/scatterpie_files/so.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;Plotting pies on ggplot/ggmap is not an easy task, as ggplot2 doesn&amp;rsquo;t provide native pie geom. The pie we produced in ggplot2 is actually a barplot transform to polar coordination. This make it difficult if we want to produce a map like the above screenshot, which was posted by Tyler Rinker, the author of R package pacman.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>跨物种计算基因相似性</title>
      <link>https://guangchuangyu.github.io/2016/12/%E8%B7%A8%E7%89%A9%E7%A7%8D%E8%AE%A1%E7%AE%97%E5%9F%BA%E5%9B%A0%E7%9B%B8%E4%BC%BC%E6%80%A7/</link>
      <pubDate>Wed, 07 Dec 2016 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/12/%E8%B7%A8%E7%89%A9%E7%A7%8D%E8%AE%A1%E7%AE%97%E5%9F%BA%E5%9B%A0%E7%9B%B8%E4%BC%BC%E6%80%A7/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Hi,&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;I know this question has been asked before a long time ago and I don&amp;rsquo;t see an answer of that question in the mailing list or in the vignette of GOsemsim package. So I was wondering what is the easiest possible way of calculating GO semantic similarity value for orthologus gene pairs between two species using the above R package or any other package you know of. I am not doing this for less annotated species I need to calculate that for orthologus genes between Human and Mouse (both of which are well annotated IMHO). So I would much appreciate it if anyone who has already done this before can point me to a resource which already has pre-calculated semantic similarity values for Mouse and Human orthologues or has inbuilt code to do that.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;Thanks &amp;amp; regards&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;这是Bioconductor support site上的&lt;a href=&#34;https://support.bioconductor.org/p/90063/&#34;&gt;问题&lt;/a&gt;，问的是他想要计算人类和老鼠的直系同源基因通过GO注释来计算语义相似性，问GOSemSim是否支持，这个答案是yes and no。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Using Linked List to solve Josephus problem</title>
      <link>https://guangchuangyu.github.io/2016/12/using-linked-list-to-solve-josephus-problem/</link>
      <pubDate>Sun, 04 Dec 2016 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/12/using-linked-list-to-solve-josephus-problem/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;这个问题是以弗拉维奥·约瑟夫斯命名的，它是1世纪的一名犹太历史学家。他在自己的日记中写道，他和他的40个战友被罗马军队包围在洞中。他们讨论是自杀还是被俘，最终决定自杀，并以抽签的方式决定谁杀掉谁。约瑟夫斯和另外一个人是最后两个留下的人。约瑟夫斯说服了那个人，他们将向罗马军队投降，不再自杀。约瑟夫斯把他的存活归因于运气或天意，他不知道是哪一个。  &amp;ndash; &lt;a href=&#34;https://zh.wikipedia.org/wiki/&#34;&gt;https://zh.wikipedia.org/wiki/&lt;/a&gt;约瑟夫斯问题&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;这是一个比较简单的问题，n个人围成圆圈，越过k-1个人，杀掉第k个人，如此反复直到只剩下最后一个人。可以用数学推导给出答案，问题本身已经足够简单，用链表可以模拟整个过程。实现起来比较直观。这里在初始化这个链表的时候，需要注意，到了最后一人的时候，他应该指向第一个人，这样才能形成一个环状的链表，然后问题就非常简单了，从第一人开始，后面就无所谓头和尾了，按照规则来，每次杀掉一个人，直到只剩下最后一人，就是结果。从维基的解释可以看出，最后两个人没死，这没节操的事情被拿来说，如果你数学好，你就可以救自己一命（站在合适的位置，让自己是最后一个）。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>中空的环形树</title>
      <link>https://guangchuangyu.github.io/2016/12/%E4%B8%AD%E7%A9%BA%E7%9A%84%E7%8E%AF%E5%BD%A2%E6%A0%91/</link>
      <pubDate>Sat, 03 Dec 2016 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/12/%E4%B8%AD%E7%A9%BA%E7%9A%84%E7%8E%AF%E5%BD%A2%E6%A0%91/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/Bioconductor/ggtree/iss95.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;这是&lt;a href=&#34;https://github.com/GuangchuangYu/ggtree/issues/95&#34;&gt;github&lt;/a&gt;上的问题，他想画环形树的时候，加一条长长的root length把tips给顶出去。&lt;/p&gt;
&lt;p&gt;这个问题在google forum上我早已解答：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>无中生有windows版R包</title>
      <link>https://guangchuangyu.github.io/2016/11/%E6%97%A0%E4%B8%AD%E7%94%9F%E6%9C%89windows%E7%89%88r%E5%8C%85/</link>
      <pubDate>Wed, 30 Nov 2016 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/11/%E6%97%A0%E4%B8%AD%E7%94%9F%E6%9C%89windows%E7%89%88r%E5%8C%85/</guid>
      <description>&lt;p&gt;之前帮助高老师实现比对序列的做图，把代码打包为R包seqcombo，方便安装使用。花两小时的作品，发现还有些用户在使用 -，-&lt;/p&gt;
&lt;p&gt;之前有人联系我说安装不上，我觉得不应该有这个问题，因为是纯R代码代码，不涉及到编译，源码包安装不应该有问题。但既然有人问，又都是windows用户，我想可以给他们提供编译好的windows包，简化安装过程（这么体贴用户，我都要被自己感动了）。&lt;/p&gt;
&lt;p&gt;放在CRAN或Bioconductor上的R包，CRAN和Bioconductor会编译出不同平台的二进制包，但seqcobo放在github上，只有源代码，没有预编译好的包，但没有不是问题，我编译好放上去就行了。&lt;/p&gt;
&lt;p&gt;但问题是我没有windows！多年来一直是OSX和linux，MacBook Pro跑Arch Linux，一台iMac跑OSX，我自己根本没有跑windows的机器，所以难为无米之炊，借台机器总是有的，但总不能每次一更新，就拷个代码去别人的机器上打包，再拷回来上传到网上，想想也是蛋疼。&lt;/p&gt;
&lt;p&gt;所以没有windows，这事干起来还不太容易，！在想怎么来无中生有生出个windows包出来的时候，我想起了rhub，也是因为没有windows，之前就用rhub来进行windows平台的R check，在把代码push到CRAN或Bioconductor之前，我总会测试没问题了，再提交代码过去，而rhub正好可以给我提供windows平台的检测。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>vertical dendrogram in ggtree</title>
      <link>https://guangchuangyu.github.io/2016/11/vertical-dendrogram-in-ggtree/</link>
      <pubDate>Tue, 29 Nov 2016 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/11/vertical-dendrogram-in-ggtree/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://twitter.com/kurai_yousei/status/799532564633518080&#34;&gt;https://twitter.com/kurai_yousei/status/799532564633518080&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.gitee.io/blog_images/ggtree/2019-11-21_14-12.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;这个Diego在推特上问的问题，他最近在写一个&lt;a href=&#34;https://github.com/ddiez/motiftools&#34;&gt;motiftools&lt;/a&gt;的R包，里面用了ggtree来画图，我想他应该是要解决他在包里的画树/聚类功能吧。&lt;/p&gt;
&lt;p&gt;他问题写的horizontal，但其实plot.hclust默认是vertical，ggtree默认也是horizontal，所以我认为他问的是vertical layout，这个在我的回答中也得到了他的确认。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>buildGOmap</title>
      <link>https://guangchuangyu.github.io/2016/11/buildgomap/</link>
      <pubDate>Mon, 28 Nov 2016 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/11/buildgomap/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/Bioconductor/clusterProfiler/640.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;周末Bioconductor上的问题，说的是他用了buildGOmap之后，在终端上输出了一长串，但没有文件产生，今天就来讲讲这个buildGOmap的前世今生。&lt;/p&gt;
&lt;p&gt;当年写clusterProfiler的时候在暨大工作，主要也是自己的需求驱动，因为实验室里有做细菌，比如肺炎链球菌D39，在细菌界基本上所谓的GO分析，就是跑个电子注释，然后数一下数目，列个表格画个饼图。很难看到有富集性分析的身影，因为绝大多数的工具是只支持少量模式生物的，还有部分工具比如支持某些细菌，支持某些植物或者某些真菌，比如支持植物的，也只是支持少量的植物物种而已，都是些自己定制给自己用的玩意，放出来只是为了顺道灌水而已。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>使用emoji画图</title>
      <link>https://guangchuangyu.github.io/2016/11/use-emoji/</link>
      <pubDate>Fri, 25 Nov 2016 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/11/use-emoji/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.gitee.io/blog_images/emojifont/2019-11-20_22-31.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;无缘无故收到好几条消息，原来是用emoji画图。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>食色性也</title>
      <link>https://guangchuangyu.github.io/2016/11/%E9%A3%9F%E8%89%B2%E6%80%A7%E4%B9%9F/</link>
      <pubDate>Mon, 21 Nov 2016 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/11/%E9%A3%9F%E8%89%B2%E6%80%A7%E4%B9%9F/</guid>
      <description>&lt;p&gt;画图配色并不是一件简单的事情，好的配色让人眼前一亮，虽然R有很多配色方案，做为ggplot2的爱好者，ggthemes也提供了很多主题，内置了很多配色方案，还有一些其它的包，比如ggtech，包含了一些科技公司比如facebook, twitter, google的典型配色方案，甚至于ggsci，提供了nature, lancet的配色方案。&lt;/p&gt;
&lt;p&gt;但这些远远不够！
但这些远远不够！
但这些远远不够！&lt;/p&gt;
&lt;p&gt;看到一张图片让我眼前一亮，我想用它的配色方案呢！我想拿最新电影的海报的配色来装个逼呢！画图时不想用现成的配色，想要另类一些，我想用一些大自然的风格，比如求偶期间各种鸟类的羽毛颜色来画！&lt;/p&gt;
&lt;p&gt;这些在R里面，都是可以的，可以的，可以的&amp;hellip;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>DNA序列差异作图</title>
      <link>https://guangchuangyu.github.io/2016/11/dna%E5%BA%8F%E5%88%97%E5%B7%AE%E5%BC%82%E4%BD%9C%E5%9B%BE/</link>
      <pubDate>Sat, 19 Nov 2016 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/11/dna%E5%BA%8F%E5%88%97%E5%B7%AE%E5%BC%82%E4%BD%9C%E5%9B%BE/</guid>
      <description>&lt;p&gt;![](&lt;a href=&#34;https://guangchuangyu.github.io/blog_images/2016/Screen&#34;&gt;https://guangchuangyu.github.io/blog_images/2016/Screen&lt;/a&gt; Shot 2016-11-17 at 8.20.21 PM.png)&lt;/p&gt;
&lt;p&gt;这是高老师&lt;a href=&#34;http://link.springer.com/article/10.1007/s11540-015-9307-3&#34;&gt;文章&lt;/a&gt;里的图，每一个小图都是通过比较两条比对序列差异而做出来的，从图A和B中可以看出，CF_YL21有可能是Mont和Oz两条序列重组而来。高老师自己做出这图后，深知手工统计序列差异、画图、拼图之困难。问我有没有办法读两条序列，生成一个图。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>blast一大坑：无法输出query sequence title</title>
      <link>https://guangchuangyu.github.io/2016/11/blast%E4%B8%80%E5%A4%A7%E5%9D%91%E6%97%A0%E6%B3%95%E8%BE%93%E5%87%BAquery-sequence-title/</link>
      <pubDate>Thu, 17 Nov 2016 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/11/blast%E4%B8%80%E5%A4%A7%E5%9D%91%E6%97%A0%E6%B3%95%E8%BE%93%E5%87%BAquery-sequence-title/</guid>
      <description>&lt;p&gt;通常做blast，我都是输出asn格式，然后用blast_formatter抽出需要的信息写成表格格式。&lt;/p&gt;
&lt;p&gt;序列的description行当然不会有重复，但是ID (第一个空白前面的字符）是有重复的，从qseqid来看，就分不清是那个序列，于是准备让blast_formatter把query title（整个description line）给输出来，结果仔细阅读了blastn -help发现不支持呀不支持！然而它支持stitle和salltitle，也就是subject的可以，但query的不行，这绝逼是一个大坑！＿|￣|○&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>align genomic features with phylogenetic tree</title>
      <link>https://guangchuangyu.github.io/2016/11/align-genomic-features-with-phylogenetic-tree/</link>
      <pubDate>Tue, 15 Nov 2016 20:10:48 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/11/align-genomic-features-with-phylogenetic-tree/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://www.biostars.org/p/218591/&#34;&gt;A question&lt;/a&gt; on biostars asking how to generate the following figure:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/Bioconductor/ggtree/ggtree_ggbio/218591.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;This can be quite easy to implement in &lt;a href=&#34;https://guangchuangyu.github.io&#34;&gt;ggtree&lt;/a&gt;, I can write a &lt;code&gt;geom&lt;/code&gt; layer to layout the alignment. As &lt;a href=&#34;https://bioconductor.org/packages/ggbio/&#34;&gt;ggbio&lt;/a&gt; already provides many &lt;code&gt;geom&lt;/code&gt; for genomic data and I don&amp;rsquo;t want to re-invent the wheel, I decided to try &lt;code&gt;ggtree+ggbio&lt;/code&gt;. This is also the beauty of &lt;code&gt;R&lt;/code&gt; that packages complete each others.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggtree: reverse time scale</title>
      <link>https://guangchuangyu.github.io/2016/11/ggtree-reverse-time-scale/</link>
      <pubDate>Tue, 08 Nov 2016 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/11/ggtree-reverse-time-scale/</guid>
      <description>&lt;p&gt;这是最近github上的问题，如何反转time scale，也就是把最近的时间设为0。而内部节点为距今多少年，这个很容易，把x轴的值变成x-max(x)就可以，感觉这个也只会在时间树上使用，所以取名revts（reverse time scale），revts之后，x轴最大值是0，其它为负数，可以使用scale_x_continuous改label为绝对值。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>showCategory parameter for visualizing compareCluster output</title>
      <link>https://guangchuangyu.github.io/2016/11/showcategory-parameter-for-visualizing-comparecluster-output/</link>
      <pubDate>Thu, 03 Nov 2016 10:30:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/11/showcategory-parameter-for-visualizing-comparecluster-output/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;I am using dotplot() to visualize results from enrichGO(), enrichDO(), enricher() and compareCluster() in clusterProfiler R package. When specifying showCategory, I get the right number of categories except with the results of compareCluser().&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;In my case, I use compareCluster() on a list of 3 elements:&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/blockquote&gt;
&lt;p&gt;str(ClusterList)
List of 3
$ All : chr [1:1450] &amp;ldquo;89886&amp;rdquo; &amp;ldquo;29923&amp;rdquo; &amp;ldquo;100132891&amp;rdquo; &amp;ldquo;101410536&amp;rdquo; &amp;hellip;
$ g1  : chr [1:858] &amp;ldquo;89886&amp;rdquo; &amp;ldquo;29923&amp;rdquo; &amp;ldquo;100132891&amp;rdquo; &amp;ldquo;101410536&amp;rdquo; &amp;hellip;
$ g2: chr [1:592] &amp;ldquo;5325&amp;rdquo; &amp;ldquo;170691&amp;rdquo; &amp;ldquo;29953&amp;rdquo; &amp;ldquo;283392&amp;rdquo; &amp;hellip;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;CompareGO_BP=compareCluster(ClusterList, fun=&amp;ldquo;enrichGO&amp;rdquo;, pvalueCutoff=0.01, pAdjustMethod=&amp;ldquo;BH&amp;rdquo;, OrgDb=org.Hs.eg.db,ont=&amp;ldquo;BP&amp;rdquo;,readable=T)&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;dotplot(CompareGO_BP, showCategory=10, title=&amp;ldquo;GO - Biological Process&amp;rdquo;)&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;I ask for 10 categories, but I get 15 categories in All, 8 categories in g1 and 12 categories in g2. None of the categories, neither the sum of the categories are 10&amp;hellip;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;Is the option showCategory working in the case of comparison? Am I missing something here?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;And which categories precisely will it plot? the most significant whatever my 3 cases or the most significant of each case?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;The question was &lt;a href=&#34;https://support.bioconductor.org/p/88965/&#34;&gt;posted&lt;/a&gt; in Bioconductor support site. It seems quite confusing and I think I need to write a post to clarify it.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>xlim_tree: set x axis limits for only Tree panel</title>
      <link>https://guangchuangyu.github.io/2016/10/xlim_tree-set-x-axis-limits-for-only-tree-panel/</link>
      <pubDate>Mon, 31 Oct 2016 12:30:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/10/xlim_tree-set-x-axis-limits-for-only-tree-panel/</guid>
      <description>&lt;p&gt;A &lt;a href=&#34;https://guangchuangyu.github.io/ggtree&#34;&gt;ggtree&lt;/a&gt; user recently asked me the following question in &lt;a href=&#34;https://groups.google.com/forum/?utm_medium=email&amp;amp;utm_source=footer#!msg/bioc-ggtree/6ec5krxpBMc/sd6jr53KBQAJ&#34;&gt;google group&lt;/a&gt;:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;I try to plot long tip labels in ggtree and usually adjust them using xlim(), however when creating a facet_plot xlim affects all plots and minimizes them.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;Is it possible to work around this and only affect the tree and it&amp;rsquo;s tip labels leaving the other plots in facet_plot unaffected?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;This is indeed a desire feature, as &lt;code&gt;ggplot2&lt;/code&gt; can&amp;rsquo;t automatically adjust &lt;code&gt;xlim&lt;/code&gt; for text since the units are in two different spaces (data and pixel).&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>facet_plot: a general solution to associate data with phylogenetic tree</title>
      <link>https://guangchuangyu.github.io/2016/10/facet_plot-a-general-solution-to-associate-data-with-phylogenetic-tree/</link>
      <pubDate>Wed, 26 Oct 2016 16:30:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/10/facet_plot-a-general-solution-to-associate-data-with-phylogenetic-tree/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://guangchuangyu.github.io/ggtree&#34;&gt;ggtree&lt;/a&gt; provides &lt;code&gt;gheatmap&lt;/code&gt; for visualizing heatmap and &lt;code&gt;msaplot&lt;/code&gt; for visualizing multiple sequence alignment with phylogenetic tree.&lt;/p&gt;
&lt;p&gt;We may have different data types and want to visualize and align them with the tree. For example, &lt;code&gt;dotplot&lt;/code&gt; of SNP site (e.g. using &lt;code&gt;geom_point(shape=&#39;|&#39;)&lt;/code&gt;), &lt;code&gt;barplot&lt;/code&gt; of trait values (e.g. using &lt;code&gt;geom_barh(stat=&#39;identity&#39;)&lt;/code&gt;) &lt;em&gt;et al&lt;/em&gt;.&lt;/p&gt;
&lt;p&gt;To make it easy to associate different types of data with phylogenetic tree, I implemented the &lt;code&gt;facet_plot&lt;/code&gt; function which accepts a &lt;code&gt;geom&lt;/code&gt; function to draw the input &lt;code&gt;data.frame&lt;/code&gt; and display it in an additional &lt;code&gt;panel&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.gitee.io/blog_images/ggtree/2019-11-20_23-16.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>[Bioc 34] NEWS of my BioC packages</title>
      <link>https://guangchuangyu.github.io/2016/10/bioc-34-news-of-my-bioc-packages/</link>
      <pubDate>Wed, 19 Oct 2016 18:13:57 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/10/bioc-34-news-of-my-bioc-packages/</guid>
      <description>&lt;p&gt;I have 7 packages published within the &lt;code&gt;Bioconductor&lt;/code&gt; project.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/ChIPseeker&#34;&gt;ChIPseeker&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/clusterProfiler&#34;&gt;clusterProfiler&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/DOSE&#34;&gt;DOSE&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/ggtree&#34;&gt;ggtree&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/GOSemSim&#34;&gt;GOSemSim&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/meshes&#34;&gt;meshes&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/ReactomePA&#34;&gt;ReactomePA&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;A new package &lt;a href=&#34;http://guangchuangyu.github.io/meshes&#34;&gt;meshes&lt;/a&gt; was included in BioC 3.4 release.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Update R packages</title>
      <link>https://guangchuangyu.github.io/2016/10/update-r-packages/</link>
      <pubDate>Wed, 19 Oct 2016 09:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/10/update-r-packages/</guid>
      <description>&lt;p&gt;更新R较为无痛的方法已经在&lt;a href=&#34;http://guangchuangyu.github.io/2014/11/hello-yosemite/&#34;&gt;hello yosemite&lt;/a&gt;一文中提及。今天Bioconductor发布3.4版本，又是更新R包的时候了。&lt;/p&gt;
&lt;p&gt;之前为了&lt;a href=&#34;https://guangchuangyu.github.io/2016/07/how-to-bug-author/&#34;&gt;吐槽&lt;/a&gt;很多人问问题都是在使用早已不维护的老版本，写了&lt;a href=&#34;https://cran.r-project.org/web/packages/rvcheck/&#34;&gt;rvcheck&lt;/a&gt;来帮忙检查版本。既然能够帮我们检查版本，自然能够帮忙升级。&lt;/p&gt;
&lt;p&gt;使用&lt;code&gt;rvcheck::update_all()&lt;/code&gt;可以自动更新CRAN, Bioconductor和Github上的R包。其实可以放到系统任务里，每月自动更新一次，然后就可以完全不用管升级的事情。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>reproducible logo generated by ggtree</title>
      <link>https://guangchuangyu.github.io/2016/10/reproducible-logo-generated-by-ggtree/</link>
      <pubDate>Fri, 14 Oct 2016 21:50:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/10/reproducible-logo-generated-by-ggtree/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://guangchuangyu.github.io/ggtree&#34;&gt;ggtree&lt;/a&gt; provides many helper functions for manupulating phylogenetic trees and make it easy to explore tree structure visually.&lt;/p&gt;
&lt;p&gt;Here, as examples, I used &lt;code&gt;ggtree&lt;/code&gt; to draw capital character &lt;code&gt;G&lt;/code&gt; and &lt;code&gt;C&lt;/code&gt;, which are first letter of my name :-).&lt;/p&gt;
&lt;p&gt;To draw a tree in such shape, we need &lt;code&gt;fan&lt;/code&gt; layout (&lt;code&gt;circular&lt;/code&gt; layout with open angle) and then rotating the tree to let the open space on the correct position. Here are the source codes to produce the &lt;code&gt;G&lt;/code&gt; and &lt;code&gt;C&lt;/code&gt; shapes of tree. I am thinking about using the &lt;code&gt;G&lt;/code&gt; shaped tree as &lt;code&gt;ggtree&lt;/code&gt; logo. Have fun with &lt;code&gt;ggtree&lt;/code&gt; :-)&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggtree for outbreak data</title>
      <link>https://guangchuangyu.github.io/2016/09/ggtree-for-outbreak-data/</link>
      <pubDate>Mon, 19 Sep 2016 20:10:48 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/09/ggtree-for-outbreak-data/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://cran.r-project.org/package=OutbreakTools&#34;&gt;OutbreakTools&lt;/a&gt; implements basic tools for the analysis of Disease Outbreaks.&lt;/p&gt;
&lt;p&gt;It defines &lt;code&gt;S4&lt;/code&gt; class &lt;code&gt;obkData&lt;/code&gt; to store case-base outbreak data. It also provides a function, &lt;code&gt;plotggphy&lt;/code&gt;, to visualize such data on the phylogenetic tree.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;library(OutbreakTools)
data(FluH1N1pdm2009)
attach(FluH1N1pdm2009)


x &amp;lt;- new(&amp;quot;obkData&amp;quot;, individuals = individuals, dna = FluH1N1pdm2009$dna,
         dna.individualID = samples$individualID, dna.date = samples$date,
         trees = FluH1N1pdm2009$trees)

plotggphy(x, ladderize = TRUE, branch.unit = &amp;quot;year&amp;quot;,
          tip.color = &amp;quot;location&amp;quot;, tip.size = 3, tip.alpha = 0.75)
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>ggtree for microbiome data</title>
      <link>https://guangchuangyu.github.io/2016/09/ggtree-for-microbiome-data/</link>
      <pubDate>Thu, 01 Sep 2016 03:17:48 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/09/ggtree-for-microbiome-data/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://onlinelibrary.wiley.com/doi/10.1111/2041-210X.12628/abstract&#34;&gt;ggtree&lt;/a&gt; can parse many software outputs and the evolution evidences inferred by these software can be used directly for tree annotation. &lt;a href=&#34;http://onlinelibrary.wiley.com/doi/10.1111/2041-210X.12628/abstract&#34;&gt;ggtree&lt;/a&gt; not only works as an infrastructure that enables evolutionary data that inferred by commonly used software packages to be used in R, but also serves as a general tree visualization and annotation tool for the R community as it supports many S3/S4 objects defined by other R packages.&lt;/p&gt;
&lt;h2 id=&#34;phyloseq-for-microbiome-data&#34;&gt;phyloseq for microbiome data&lt;/h2&gt;
&lt;p&gt;&lt;code&gt;phyloseq&lt;/code&gt; class defined in the &lt;a href=&#34;https://www.bioconductor.org/package/phyloseq&#34;&gt;phyloseq&lt;/a&gt; package was designed for microbiome data. &lt;code&gt;phyloseq&lt;/code&gt; package implemented &lt;code&gt;plot_tree&lt;/code&gt; function using &lt;code&gt;ggplot2&lt;/code&gt;. Although the function was implemented by &lt;code&gt;ggplot2&lt;/code&gt; and we can use &lt;code&gt;theme&lt;/code&gt;, &lt;code&gt;scale_color_manual&lt;/code&gt; etc for customization, the most valuable part of &lt;code&gt;ggplot2&lt;/code&gt;, adding layer, is missing. &lt;code&gt;plot_tree&lt;/code&gt; only provides limited parameters to control the output graph and it is hard to add layer unless user has expertise in both &lt;code&gt;phyloseq&lt;/code&gt; and &lt;code&gt;ggplot2&lt;/code&gt;.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggtree paper published</title>
      <link>https://guangchuangyu.github.io/2016/08/ggtree-paper-published/</link>
      <pubDate>Tue, 16 Aug 2016 22:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/08/ggtree-paper-published/</guid>
      <description>&lt;p&gt;Today &lt;a href=&#34;https://guangchuangyu.github.io/ggtree&#34;&gt;&lt;code&gt;ggtree&lt;/code&gt;&lt;/a&gt; received &lt;a href=&#34;https://github.com/GuangchuangYu/ggtree/stargazers&#34;&gt;100 stars&lt;/a&gt; on &lt;!-- raw HTML omitted --&gt;&lt;!-- raw HTML omitted --&gt; and I found the paper was &lt;a href=&#34;http://dx.doi.org/10.1111/2041-210X.12628&#34;&gt;online&lt;/a&gt; at the same day by the tweet:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.gitee.io/blog_images/ggtree/2019-11-20_23-17.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>using meshes for MeSH Enrichment Analysis</title>
      <link>https://guangchuangyu.github.io/2016/08/using-meshes-for-mesh-enrichment-analysis/</link>
      <pubDate>Wed, 03 Aug 2016 00:19:15 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/08/using-meshes-for-mesh-enrichment-analysis/</guid>
      <description>&lt;p&gt;MeSH (Medical Subject Headings) is the NLM (U.S. National Library of
Medicine) controlled vocabulary used to manually index articles for
MEDLINE/PubMed. MeSH is comprehensive life science vocabulary. MeSH has
19 categories and &lt;code&gt;MeSH.db&lt;/code&gt; contains 16 of them. That is:&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>leading edge analysis</title>
      <link>https://guangchuangyu.github.io/2016/07/leading-edge-analysis/</link>
      <pubDate>Wed, 20 Jul 2016 18:58:10 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/07/leading-edge-analysis/</guid>
      <description>&lt;h2 id=&#34;leading-edge-and-core-enrichment&#34;&gt;leading edge and core enrichment&lt;/h2&gt;
&lt;p&gt;Leading edge analysis reports &lt;code&gt;Tags&lt;/code&gt; to indicate the percentage of genes contributing to the enrichment score, &lt;code&gt;List&lt;/code&gt; to indicate where in the list the enrichment score is attained and &lt;code&gt;Signal&lt;/code&gt; for enrichment signal strength.&lt;/p&gt;
&lt;p&gt;It would also be very interesting to get the core enriched genes that contribute to the enrichment.&lt;/p&gt;
&lt;p&gt;Now &lt;a href=&#34;https://guangchuangyu.github.io/DOSE&#34;&gt;DOSE&lt;/a&gt;, &lt;a href=&#34;https://guangchuangyu.github.io/clusterProfiler&#34;&gt;clusterProfiler&lt;/a&gt; and &lt;a href=&#34;https://guangchuangyu.github.io/ReactomePA&#34;&gt;ReactomePA&lt;/a&gt; all support leading edge analysis and report core enriched genes.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Evolution of my BioC packages</title>
      <link>https://guangchuangyu.github.io/2016/07/evolution-of-my-bioc-packages/</link>
      <pubDate>Wed, 13 Jul 2016 21:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/07/evolution-of-my-bioc-packages/</guid>
      <description>&lt;p&gt;发现Youtube上有一个视频叫&lt;a href=&#34;https://www.youtube.com/watch?v=MYTblx-5Yog&#34;&gt;Evolution of clusterProfiler&lt;/a&gt;, 是Landon Wilkins用&lt;a href=&#34;http://gource.io/&#34;&gt;Gource&lt;/a&gt;做的。于是我也来玩一下，看一下自己这几年码代码的过程。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>How to bug author</title>
      <link>https://guangchuangyu.github.io/2016/07/how-to-bug-author/</link>
      <pubDate>Tue, 05 Jul 2016 20:13:35 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/07/how-to-bug-author/</guid>
      <description>
&lt;script src=&#34;https://guangchuangyu.github.io/rmarkdown-libs/header-attrs/header-attrs.js&#34;&gt;&lt;/script&gt;


&lt;p&gt;As an author of several Bioconductor packages. I found many questions from users are quite annoying. Some of them never use google and they are reluctant to read vignettes.&lt;/p&gt;
&lt;div id=&#34;step-1-make-sure-you-are-using-the-latest-release&#34; class=&#34;section level3&#34;&gt;
&lt;h3&gt;Step 1: make sure you are using the latest release&lt;/h3&gt;
&lt;p&gt;I found many peoples are using out-of-date packages. When they got an issue of an out-dated package, they never check whether the issue still exists in latest release.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>identify method for ggtree</title>
      <link>https://guangchuangyu.github.io/2016/06/identify-method-for-ggtree/</link>
      <pubDate>Tue, 28 Jun 2016 14:30:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/06/identify-method-for-ggtree/</guid>
      <description>&lt;p&gt;We are happy to announce that &lt;code&gt;ggtree&lt;/code&gt; supports interactive tree annotation/manipulation by implementing an &lt;code&gt;identify&lt;/code&gt; method. Users can click on a node to highlight a clade, to label or rotate it &lt;em&gt;etc&lt;/em&gt;.&lt;/p&gt;
&lt;p&gt;Here is an example of highlighting clades using &lt;code&gt;geom_hilight&lt;/code&gt; with &lt;code&gt;identify&lt;/code&gt;:&lt;/p&gt;

&lt;div style=&#34;position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;&#34;&gt;
  &lt;iframe src=&#34;https://www.youtube.com/embed/KcF8Ec38mzI&#34; style=&#34;position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;&#34; allowfullscreen title=&#34;YouTube Video&#34;&gt;&lt;/iframe&gt;
&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>第九届ChinaR会议生物信息学分会</title>
      <link>https://guangchuangyu.github.io/2016/05/%E7%AC%AC%E4%B9%9D%E5%B1%8Achinar%E4%BC%9A%E8%AE%AE%E7%94%9F%E7%89%A9%E4%BF%A1%E6%81%AF%E5%AD%A6%E5%88%86%E4%BC%9A/</link>
      <pubDate>Tue, 31 May 2016 18:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/05/%E7%AC%AC%E4%B9%9D%E5%B1%8Achinar%E4%BC%9A%E8%AE%AE%E7%94%9F%E7%89%A9%E4%BF%A1%E6%81%AF%E5%AD%A6%E5%88%86%E4%BC%9A/</guid>
      <description>&lt;p&gt;不记得是什么时候知道统计之都的，但我记得最早知道的是太云，因为我用了他写的&lt;a href=&#34;https://cran.r-project.org/package=corrplot&#34;&gt;corrplot&lt;/a&gt;包。后来统计之都最早接触的也是太云，他给我写邮件问我能不能帮忙校对&lt;a href=&#34;https://book.douban.com/subject/24527091/&#34;&gt;《ggplot2：数据分析与图形艺术》&lt;/a&gt;，从此开始和太云变成了网友。&lt;/p&gt;
&lt;p&gt;我在暨大的时候，太云曾经邀请我去China-R会议做报告，但我觉得自己没什么好分享的，&lt;a href=&#34;http://guangchuangyu.github.io/GOSemSim&#34;&gt;GOSemSim&lt;/a&gt;这个包是硕士的时候做的，不好去讲之前做的东西。而当时我写的另一个包&lt;a href=&#34;http://guangchuangyu.github.io/clusterProfiler&#34;&gt;clusterProfiler&lt;/a&gt;，纯粹是因为大量做富集分析的工具都是针对模式生物，而我们实验室有做各种细菌；另外有一些工具，背景设置是有问题的。自己实现一个包，不受别人的限制。即便是这个包现在受到了一定的认可，比如BioC 3.3中有个&lt;a href=&#34;http://bioconductor.org/packages/release/bioc/html/debrowser.html&#34;&gt;debrowser&lt;/a&gt;的包使用了clusterProfiler，而在BioC 3.4中又有个新包&lt;a href=&#34;http://bioconductor.org/packages/devel/bioc/html/bioCancer.html&#34;&gt;bioCancer&lt;/a&gt;也使用了clusterProfiler；再比如这次在北京，有好几个参会的人员在茶歇时问了clusterProfiler的问题。但始终觉得这只是个实用性的包而已，算法是别人的，而且已经比较老了，类似的工具简直就是成百上千。所以也是不好意思拿出来讲的。所以我拒绝了太云的邀请，一直也没有参加China-R的会议。&lt;/p&gt;
&lt;p&gt;今年是第九届China-R会议，这次会议规模很大，有22个分会场，超过100个演讲嘉宾，参会人数超过4000人。这一次刚好有个Bioconductor的分会场，Matt写信给我，说我写过几个Bioconductor包，他本人喜欢我的&lt;a href=&#34;http://guangchuangyu.github.io/ChIPseeker&#34;&gt;ChIPseeker&lt;/a&gt;包，问我能否在会上分享与Bioconductor包相关的经验。这是Bioconductor在中国的首秀，我欣然接受，当然也是因为这两年我写了&lt;a href=&#34;http://guangchuangyu.github.io/ChIPseeker&#34;&gt;ChIPseeker&lt;/a&gt;和&lt;a href=&#34;http://guangchuangyu.github.io/ggtree&#34;&gt;ggtree&lt;/a&gt;，我自己觉得还拿得出手🙈。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>[Bioc 33] NEWS of my BioC packages</title>
      <link>https://guangchuangyu.github.io/2016/05/bioc-33-news-of-my-bioc-packages/</link>
      <pubDate>Thu, 05 May 2016 20:13:57 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/05/bioc-33-news-of-my-bioc-packages/</guid>
      <description>&lt;!-- raw HTML omitted --&gt;
&lt;p&gt;Today is my birthday and it happened to be the release day of Bioconductor 3.3. It&amp;rsquo;s again the time to reflect what I&amp;rsquo;ve done in the past year.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/ChIPseeker&#34;&gt;ChIPseeker&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/clusterProfiler&#34;&gt;clusterProfiler&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/DOSE&#34;&gt;DOSE&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/ggtree&#34;&gt;ggtree&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/GOSemSim&#34;&gt;GOSemSim&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;http://guangchuangyu.github.io/ReactomePA&#34;&gt;ReactomePA&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;</description>
    </item>
    
    <item>
      <title>convert biological ID with KEGG API using clusterProfiler</title>
      <link>https://guangchuangyu.github.io/2016/05/convert-biological-id-with-kegg-api-using-clusterprofiler/</link>
      <pubDate>Tue, 03 May 2016 17:00:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/05/convert-biological-id-with-kegg-api-using-clusterprofiler/</guid>
      <description>&lt;h2 id=&#34;bitr_kegg&#34;&gt;bitr_kegg&lt;/h2&gt;
&lt;p&gt;&lt;code&gt;clusterProfiler&lt;/code&gt; can convert biological IDs using &lt;code&gt;OrgDb&lt;/code&gt; object via the &lt;code&gt;bitr&lt;/code&gt; function. Now I implemented another function, &lt;code&gt;bitr_kegg&lt;/code&gt; for converting IDs through KEGG API.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;library(clusterProfiler)
data(gcSample)
hg &amp;lt;- gcSample[[1]]
head(hg)

## [1] &amp;quot;4597&amp;quot;  &amp;quot;7111&amp;quot;  &amp;quot;5266&amp;quot;  &amp;quot;2175&amp;quot;  &amp;quot;755&amp;quot;   &amp;quot;23046&amp;quot;

eg2np &amp;lt;- bitr_kegg(hg, fromType=&#39;kegg&#39;, toType=&#39;ncbi-proteinid&#39;, organism=&#39;hsa&#39;)

## Warning in bitr_kegg(hg, fromType = &amp;quot;kegg&amp;quot;, toType = &amp;quot;ncbi-proteinid&amp;quot;,
## organism = &amp;quot;hsa&amp;quot;): 3.7% of input gene IDs are fail to map...

head(eg2np)

##     kegg ncbi-proteinid
## 1   8326      NP_003499
## 2  58487   NP_001034707
## 3 139081      NP_619647
## 4  59272      NP_068576
## 5    993      NP_001780
## 6   2676      NP_001487

np2up &amp;lt;- bitr_kegg(eg2np[,2], fromType=&#39;ncbi-proteinid&#39;, toType=&#39;uniprot&#39;, organism=&#39;hsa&#39;)

head(np2up)

##   ncbi-proteinid uniprot
## 1      NP_005457  O75586
## 2      NP_005792  P41567
## 3      NP_005792  Q6IAV3
## 4      NP_037536  Q13421
## 5      NP_006054  O60662
## 6   NP_001092002  O95398
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The ID type (both fromType &amp;amp; toType) should be one of &amp;lsquo;kegg&amp;rsquo;, &amp;lsquo;ncbi-geneid&amp;rsquo;, &amp;lsquo;ncbi-proteinid&amp;rsquo; or &amp;lsquo;uniprot&amp;rsquo;. The &amp;lsquo;kegg&amp;rsquo; is the primary ID used in KEGG database. The data source of KEGG was from NCBI. A rule of thumb for the &amp;lsquo;kegg&amp;rsquo; ID is &lt;code&gt;entrezgene&lt;/code&gt; ID for eukaryote species and &lt;code&gt;Locus&lt;/code&gt; ID for prokaryotes.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>KEGG Module Enrichment Analysis</title>
      <link>https://guangchuangyu.github.io/2016/04/kegg-module-enrichment-analysis/</link>
      <pubDate>Wed, 13 Apr 2016 20:48:15 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/04/kegg-module-enrichment-analysis/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;KEGG MODULE is a collection of manually defined functional units, called KEGG modules and identified by the M numbers, used for annotation and biological interpretation of sequenced genomes. There are four types of KEGG modules:&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;ul&gt;
&lt;li&gt;pathway modules – representing tight functional units in KEGG metabolic pathway maps, such as M00002 (Glycolysis, core module involving three-carbon compounds)&lt;/li&gt;
&lt;li&gt;structural complexes – often forming molecular machineries, such as M00072 (Oligosaccharyltransferase)&lt;/li&gt;
&lt;li&gt;functional sets – for other types of essential sets, such as M00360 (Aminoacyl-tRNA synthases, prokaryotes)&lt;/li&gt;
&lt;li&gt;signature modules – as markers of phenotypes, such as M00363 (EHEC pathogenicity signature, Shiga toxin)&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>yet an unofficial BioEdit for OSX</title>
      <link>https://guangchuangyu.github.io/2016/03/yet-an-unofficial-bioedit-for-osx/</link>
      <pubDate>Wed, 30 Mar 2016 13:40:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/03/yet-an-unofficial-bioedit-for-osx/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://www.mbio.ncsu.edu/bioedit/bioedit.html&#34;&gt;&lt;img src=&#34;http://www.mbio.ncsu.edu/bioedit/Banner1.GIF&#34; alt=&#34;&#34;&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;To my knowledge, &lt;a href=&#34;http://www.mbio.ncsu.edu/bioedit/bioedit.html&#34;&gt;BioEdit&lt;/a&gt; is the most comprehensive biological sequence alignment editor. Most of my labmates run this software using &lt;code&gt;Parallels Desktop&lt;/code&gt;. For some of them, BioEdit is the only reason to install &lt;code&gt;Parallels Desktop&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;I need to edit my alignment recently, and install it in my iMac using &lt;a href=&#34;https://www.winehq.org/&#34;&gt;Wine&lt;/a&gt;, which is a compatibility layer for running Windows applications on POSIX-compliant OS. Although it is famous in Linux community for many years, many OSX users never heard of it.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Google Drive @ HKU</title>
      <link>https://guangchuangyu.github.io/2016/03/google-drive-hku/</link>
      <pubDate>Thu, 24 Mar 2016 15:40:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/03/google-drive-hku/</guid>
      <description>&lt;p&gt;寻找一个好的网盘一直是个困扰我的问题，Dropbox非常好，但空间有限，大陆的各种网盘都是渣渣，本来试用了一下&lt;a href=&#34;http://guangchuangyu.github.io/2014/05/%E6%9B%B4%E6%94%B9%E7%99%BE%E5%BA%A6%E4%BA%91%E5%90%8C%E6%AD%A5%E7%9B%98%E8%B7%AF%E5%BE%84/&#34;&gt;百度云&lt;/a&gt;，但度娘实在不争气，体验非常差。我后来找到了个比较好的方案，那就是&lt;a href=&#34;https://gitlab.com/&#34;&gt;gitlab&lt;/a&gt;，可以创建无限量的project，每个project有10G的空间，这比&lt;a href=&#34;https://github.com/&#34;&gt;github&lt;/a&gt;出手大方多了。唯一不足是&lt;code&gt;.git&lt;/code&gt;文件夹也是非常占空间的。&lt;/p&gt;
&lt;p&gt;到HKU两年多，才发现HKU的邮箱自带无限量的google drive网盘。&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2016/google_drive.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>embed images in ggplot2 via subview and annotate a phylogenetic tree with images using inset function</title>
      <link>https://guangchuangyu.github.io/2016/03/embed-images-in-ggplot2-via-subview-and-annotate-a-phylogenetic-tree-with-images-using-inset-function/</link>
      <pubDate>Sun, 20 Mar 2016 10:50:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/03/embed-images-in-ggplot2-via-subview-and-annotate-a-phylogenetic-tree-with-images-using-inset-function/</guid>
      <description>&lt;p&gt;I extended the &lt;a href=&#34;http://guangchuangyu.github.io/2015/08/subview/&#34;&gt;subview&lt;/a&gt; function to support embed image file in a &lt;code&gt;ggplot&lt;/code&gt; object.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;set.seed(123)
d = data.frame(x=rnorm(10), y=rnorm(10))

imgfile &amp;lt;- tempfile(, fileext=&amp;quot;.png&amp;quot;)
download.file(&amp;quot;https://avatars1.githubusercontent.com/u/626539?v=3&amp;amp;u=e731426406dd3f45a73d96dd604bc45ae2e7c36f&amp;amp;s=140&amp;quot;,
	          destfile=imgfile, mode=&#39;wb&#39;)

p = ggplot(d, aes(x, y))
subview(p, imgfile, x=d$x[1], y=d$y[1]) + geom_point(size=5)
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>Font Awesome supported in emojifont</title>
      <link>https://guangchuangyu.github.io/2016/03/font-awesome-supported-in-emojifont/</link>
      <pubDate>Mon, 14 Mar 2016 16:21:11 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/03/font-awesome-supported-in-emojifont/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://cran.r-project.org/package=emojifont&#34;&gt;&lt;img src=&#34;http://www.r-pkg.org/badges/version/emojifont&#34; alt=&#34;CRAN_Status_Badge&#34;&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://cran.r-project.org/web/packages/emojifont/index.html&#34;&gt;&lt;code&gt;emojifont&lt;/code&gt;&lt;/a&gt; is available in CRAN, you can use the following command to install it.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;install.packages(&amp;quot;emojifont&amp;quot;)
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;An example of using emoji font in R plot is showed below:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2016/douban_emoji.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>使用ggtree实现进化树的可视化和注释</title>
      <link>https://guangchuangyu.github.io/2016/03/ggtree-for-tree-visualization-annotation/</link>
      <pubDate>Wed, 09 Mar 2016 13:17:48 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/03/ggtree-for-tree-visualization-annotation/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;本文受魏太云（&lt;a href=&#34;http://www.weibo.com/taiyun&#34;&gt;@cloud_wei&lt;/a&gt;)的邀请，最初在2015年发表于&lt;a href=&#34;http://cos.name/2015/11/to-achieve-the-visualization-and-annotation-of-evolutionary-tree-using-ggtree/&#34;&gt;统计之都&lt;/a&gt;。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;进化树看起来和层次聚类很像。有必要解释一下两者的一些区别。&lt;/p&gt;
&lt;p&gt;层次聚类的侧重点在于分类，把距离近的聚在一起。而进化树的构建可以说也是一个聚类过程，但侧重点在于推测进化关系和进化距离(evolutionary distance)。&lt;/p&gt;
&lt;p&gt;层次聚类的输入是距离，比如euclidean或manhattan距离。把距离近的聚在一起。而进化树推断是从生物序列（DNA或氨基酸）的比对开始。最简单的方法是计算一下序列中不匹配的数目，称之为hamming distance（通常用序列长度做归一化），使用距离当然也可以应用层次聚类的方法。进化树的构建最简单的方法是非加权配对平均法（Unweighted Pair Group Method with Arithmetic Mean, UPGMA），这其实是使用average linkage的层次聚类。这种方法在进化树推断上现在基本没人用。更为常用的是邻接法（neighbor joining），两个节点距离其它节点都比较远，而这两个节点又比较近，它们就是neighbor，可以看出neighbor不一定是距离最近的两个节点。真正做进化的人，这个方法也基本不用。现在主流的方法是最大似然法(Maximum likelihood, ML)，通过进化模型（evolutionary model)估计拓朴结构和分支长度，估计的结果具有最高的概率能够产生观测数据（多序列比对）。另外还有最大简约法和贝叶斯推断等方法用于构建进化树。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>covplot supports GRangesList</title>
      <link>https://guangchuangyu.github.io/2016/02/covplot-supports-grangeslist/</link>
      <pubDate>Mon, 29 Feb 2016 11:45:08 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/02/covplot-supports-grangeslist/</guid>
      <description>&lt;p&gt;To answer the &lt;a href=&#34;https://github.com/GuangchuangYu/ChIPseeker/issues/27&#34;&gt;issue&lt;/a&gt;, I extend the &lt;code&gt;covplot&lt;/code&gt; function to support viewing coverage of a list of &lt;code&gt;GRanges&lt;/code&gt; objects or &lt;code&gt;bed&lt;/code&gt; files.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;library(ChIPseeker)
files &amp;lt;- getSampleFiles()
peak=GenomicRanges::GRangesList(CBX6=readPeakFile(files[[4]]),
                                CBX7=readPeakFile(files[[5]]))

p &amp;lt;- covplot(peak)
print(p)
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>tweets of ggtree</title>
      <link>https://guangchuangyu.github.io/2016/02/tweets-of-ggtree/</link>
      <pubDate>Tue, 23 Feb 2016 11:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/02/tweets-of-ggtree/</guid>
      <description>&lt;!-- raw HTML omitted --&gt;
&lt;!-- raw HTML omitted --&gt;
&lt;!-- raw HTML omitted --&gt;</description>
    </item>
    
    <item>
      <title>ggtree supports phylip tree format</title>
      <link>https://guangchuangyu.github.io/2016/01/ggtree-supports-phylip-tree-format/</link>
      <pubDate>Fri, 15 Jan 2016 13:19:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/01/ggtree-supports-phylip-tree-format/</guid>
      <description>&lt;p&gt;Phylip is also a widely used tree format, which contains taxa sequences with Newick tree text.&lt;/p&gt;
&lt;p&gt;In &lt;code&gt;ggtree&lt;/code&gt;, we can use &lt;code&gt;read.phylip()&lt;/code&gt; function to parse the file and use &lt;code&gt;ggtree()&lt;/code&gt; to visualize the tree.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>label edge number in ggtree</title>
      <link>https://guangchuangyu.github.io/2016/01/label-edge-number-in-ggtree/</link>
      <pubDate>Wed, 13 Jan 2016 11:00:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/01/label-edge-number-in-ggtree/</guid>
      <description>&lt;p&gt;This is a question from &lt;code&gt;ggtree&lt;/code&gt; user. In &lt;code&gt;ape&lt;/code&gt; and &lt;code&gt;phytools&lt;/code&gt;, it&amp;rsquo;s easy to label edge using the &lt;code&gt;edgelabels&lt;/code&gt; function.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;set.seed(1)
tr = rtree(30)
library(ape)
plot(tr, main=&amp;quot;ape&amp;quot;)
edgelabels()
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>Annotate a phylogenetic tree with insets</title>
      <link>https://guangchuangyu.github.io/2016/01/annotate-a-phylogenetic-tree-with-insets/</link>
      <pubDate>Mon, 11 Jan 2016 19:36:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/01/annotate-a-phylogenetic-tree-with-insets/</guid>
      <description>&lt;p&gt;&lt;code&gt;ggtree&lt;/code&gt; implemented a function, &lt;code&gt;subview&lt;/code&gt;, that can add subplots on a
ggplot2 object. It had successful applied to &lt;a href=&#34;http://stackoverflow.com/questions/10368180/plotting-pie-graphs-on-map-in-ggplot/32380396#32380396&#34;&gt;plot pie graphs on map&lt;/a&gt;.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;set.seed(2016-01-04)
tr &amp;lt;- rtree(30)
tr &amp;lt;- groupClade(tr, node=45)
p &amp;lt;- ggtree(tr, aes(color=group)) + geom_tippoint()
cpos &amp;lt;- get_clade_position(p, node=45)
p1 &amp;lt;- p + geom_hilight(node=45)
p2 &amp;lt;- with(cpos, p+xlim(xmin, xmax*1.01)+ylim(ymin, ymax))
with(cpos, subview(p2+geom_tiplab(), p1+theme_transparent(), x=xmin+(xmax-xmin)*.15, y=ymin+(ymax-ymin)*.85))
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>GO analysis using clusterProfiler</title>
      <link>https://guangchuangyu.github.io/2016/01/go-analysis-using-clusterprofiler/</link>
      <pubDate>Mon, 04 Jan 2016 11:58:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2016/01/go-analysis-using-clusterprofiler/</guid>
      <description>&lt;p&gt;&lt;code&gt;clusterProfiler&lt;/code&gt; supports over-representation test and gene set
enrichment analysis of Gene Ontology. It supports GO annotation from
OrgDb object, GMT file and user&amp;rsquo;s own data.&lt;/p&gt;
&lt;h2 id=&#34;support-many-species&#34;&gt;support many species&lt;/h2&gt;
&lt;p&gt;In github version of clusterProfiler, &lt;code&gt;enrichGO&lt;/code&gt; and &lt;code&gt;gseGO&lt;/code&gt; functions
removed the parameter &lt;em&gt;organism&lt;/em&gt; and add another parameter &lt;em&gt;OrgDb&lt;/em&gt;, so
that any species that have &lt;code&gt;OrgDb&lt;/code&gt; object available can be analyzed in
&lt;strong&gt;clusterProfiler&lt;/strong&gt;. Bioconductor have already provide OrgDb for about
20 species, see
&lt;a href=&#34;http://bioconductor.org/packages/release/BiocViews.html#___OrgDb&#34;&gt;http://bioconductor.org/packages/release/BiocViews.html#___OrgDb&lt;/a&gt;, and
users can build &lt;code&gt;OrgDb&lt;/code&gt; via &lt;code&gt;AnnotationHub&lt;/code&gt;.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>News of ggtree</title>
      <link>https://guangchuangyu.github.io/2015/12/news-of-ggtree/</link>
      <pubDate>Wed, 30 Dec 2015 14:11:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/12/news-of-ggtree/</guid>
      <description>&lt;p&gt;A new version of &lt;a href=&#34;https://github.com/GuangchuangYu/ggtree&#34;&gt;ggtree&lt;/a&gt; that works with ggplot2 (version &amp;gt;= 2.0.0) is now availabel.&lt;/p&gt;
&lt;h2 id=&#34;new-layers&#34;&gt;new layers&lt;/h2&gt;
&lt;p&gt;Some functions, &lt;em&gt;add_legend&lt;/em&gt;, &lt;em&gt;hilight&lt;/em&gt;, &lt;em&gt;annotation_clade&lt;/em&gt; and &lt;em&gt;annotation_clade2&lt;/em&gt; were removed. Instead we provide layer functions, &lt;code&gt;geom_treescale&lt;/code&gt;, &lt;code&gt;geom_hilight&lt;/code&gt; and &lt;code&gt;geom_cladelabel&lt;/code&gt;. You can use &lt;code&gt;+&lt;/code&gt; operator to add layers using these layer functions.&lt;/p&gt;
&lt;p&gt;In addtion, we provide &lt;code&gt;geom_point2&lt;/code&gt;, &lt;code&gt;geom_text2&lt;/code&gt; and &lt;code&gt;geom_segment2&lt;/code&gt; which works exactly as &lt;code&gt;geom_point&lt;/code&gt;, &lt;code&gt;geom_text&lt;/code&gt; and &lt;code&gt;geom_segment&lt;/code&gt; except they allow ggtree users to do &lt;a href=&#34;http://guangchuangyu.github.io/2015/09/subsetting-data-in-ggtree/&#34;&gt;subsetting&lt;/a&gt;.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>use emoji font in R</title>
      <link>https://guangchuangyu.github.io/2015/12/use-emoji-font-in-r/</link>
      <pubDate>Wed, 16 Dec 2015 11:11:11 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/12/use-emoji-font-in-r/</guid>
      <description>&lt;p&gt;![](&lt;a href=&#34;http://guangchuangyu.github.io/blog_images/2015/Screenshot&#34;&gt;http://guangchuangyu.github.io/blog_images/2015/Screenshot&lt;/a&gt; 2015-12-16 10.55.49.png)&lt;/p&gt;
&lt;p&gt;I have played with emoji in &lt;code&gt;R&lt;/code&gt; for a while. My solution of using it is different from what implemented in &lt;a href=&#34;https://github.com/dill/emoGG/&#34;&gt;emoGG&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;code&gt;emoGG&lt;/code&gt; is a good attemp to add &lt;code&gt;emoji&lt;/code&gt; in &lt;code&gt;ggplot2&lt;/code&gt;. It render &lt;code&gt;emoji&lt;/code&gt; picture (png) and creat a layer, &lt;code&gt;geom_emoji&lt;/code&gt;, to add emoji.&lt;/p&gt;
&lt;p&gt;In my opinion, &lt;code&gt;emoji&lt;/code&gt; should be treated as ordinary font in user interface, albeit it maynot be true internally.&lt;/p&gt;
&lt;p&gt;It would be more flexible if we can use emoji as ordinary font and in this way user don&amp;rsquo;t need to learn extra stuff.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>喜新厌旧之hello Hugo</title>
      <link>https://guangchuangyu.github.io/2015/12/%E5%96%9C%E6%96%B0%E5%8E%8C%E6%97%A7%E4%B9%8Bhello-hugo/</link>
      <pubDate>Fri, 04 Dec 2015 00:42:26 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/12/%E5%96%9C%E6%96%B0%E5%8E%8C%E6%97%A7%E4%B9%8Bhello-hugo/</guid>
      <description>&lt;p&gt;最早在China Unix上写博客，后来转战新浪。在&lt;a href=&#34;http://azaleasays.com/&#34;&gt;azelea&lt;/a&gt;的说服下，&lt;a href=&#34;http://guangchuangyu.github.io/2008/09/%E5%8D%9A%E5%AE%A2%E8%BD%ACwordpress/&#34;&gt;果断换成wordpress&lt;/a&gt;，写技术博客贴点代码什么的，新浪必须是太渣。&lt;a href=&#34;http://azaleasays.com/&#34;&gt;azelea&lt;/a&gt;是我开始独立博客的领路人，为我提供了空间和域名。再后来自己买了空间和&lt;code&gt;ygc.name&lt;/code&gt;的域名，用了好几年。本来一直有想法要换成github+jekll，恰巧&lt;a href=&#34;http://blog.shenwei.me/&#34;&gt;Wei Shen&lt;/a&gt;强力推荐HUGO。于是再一次换博客。&lt;/p&gt;
&lt;p&gt;首先面临着wordpress迁移的问题。&lt;/p&gt;
&lt;h1 id=&#34;导入wordpress-posts为markdown文件&#34;&gt;导入wordpress posts为markdown文件&lt;/h1&gt;
&lt;p&gt;试用了多个插件或脚本，都是各种出错。最后发现了神器&lt;a href=&#34;https://github.com/jprichardson/potter-wordpress&#34;&gt;potter-wordpress&lt;/a&gt;，通过npm安装：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;npm install -g pottercms-wordpress
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;然后一个语句:&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;potter-wordpress -h WORDPRESS_SITE_URL -u USER_NAME -p PASSWORD --dir PATH_TO_STORE_MD_FILES
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;自动从线上把posts抓下来，并转化为&lt;code&gt;markdown&lt;/code&gt;。在之前各种搞不定之后，看到下面的输出有种莫名的快感。&lt;/p&gt;
&lt;p&gt;Fetching articles&amp;hellip;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;   Got : [Sun Nov 29 2015] R kernel in Jupyter notebook 3
   Got : [Mon Nov 09 2015] phylomoji with ggtree
   Got : [Tue Nov 17 2015] 合体中的操作系统
   Got : [Mon Nov 02 2015] Comparison of clusterProfiler and GSEA-P
   Got : [Thu Oct 01 2015] ChIPseq data mining with ChIPseeker
   Got : [Tue Oct 06 2015] TRIE
   Got : [Thu Oct 15 2015] [BioC 3.2] NEWS of my BioC packages
   Got : [Wed Oct 21 2015] use simplify to remove redundancy of enriched GO terms
   
   ...
   
   Got : [Mon May 14 2007] Edit partition table in NetBSD/macppc
   Got : [Mon May 14 2007] 我的emacs配置文件
   Got : [Mon May 14 2007] pkgsrc tips
   Got : [Thu May 03 2007] scilab三维平面绘图
   Got : [Sat Jun 24 2006] qvwm窗口管理器的windows2000主题
   Got : [Wed Jun 14 2006] 安装os9和netbsd双系统
   Got : [Sat May 28 2005] 在emacs里使用maxima
   Got : [Mon Mar 14 2005] scau校园网认证
   Got : [Fri Jan 14 2005] Powerbook G3上安装gentoo
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Done.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>R kernel in Jupyter notebook 3</title>
      <link>https://guangchuangyu.github.io/2015/11/r-kernel-in-jupyter-notebook-3/</link>
      <pubDate>Sun, 29 Nov 2015 14:13:35 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/11/r-kernel-in-jupyter-notebook-3/</guid>
      <description>&lt;p&gt;I followed the post, &lt;a href=&#34;http://www.michaelpacer.com/maths/r-kernel-for-ipython-notebook&#34;&gt;Installing an R kernel for IPython/jupyter notebook 3 on OSX&lt;/a&gt;,
to install jupyter with python3 and R kernels in my iMac.&lt;/p&gt;
&lt;p&gt;I have &lt;a href=&#34;https://elementary.io/&#34;&gt;elementaryOS&lt;/a&gt; on my Macbook Pro and also
want to have jupyter on it. The installation process is quite similar.&lt;/p&gt;
&lt;h3 id=&#34;install-jupyter&#34;&gt;Install Jupyter&lt;/h3&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;sudo apt-get install python3-pip
sudo pip3 install jupyter
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>合体中的操作系统</title>
      <link>https://guangchuangyu.github.io/2015/11/%E5%90%88%E4%BD%93%E4%B8%AD%E7%9A%84%E6%93%8D%E4%BD%9C%E7%B3%BB%E7%BB%9F/</link>
      <pubDate>Tue, 17 Nov 2015 16:06:59 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/11/%E5%90%88%E4%BD%93%E4%B8%AD%E7%9A%84%E6%93%8D%E4%BD%9C%E7%B3%BB%E7%BB%9F/</guid>
      <description>&lt;p&gt;更新EI Capitan已经近一个月，第一感觉就是明显变慢了。这是去年买的27&#39; iMac，必须不慢。
MS office程序可以打开，但打开文档直接闪退。升级安装总会有些问题，就像我去年在笔记本上&lt;a href=&#34;http://guangchuangyu.github.io/2014/11/hello-yosemite/&#34;&gt;升级yosemite&lt;/a&gt;一样，最后两分钟始终过不去，迫使我&lt;a href=&#34;http://guangchuangyu.github.io/2014/11/hello-yosemite/&#34;&gt;全新安装&lt;/a&gt;，当时我看后台记录就发现了是MacTex拷不过去，
后来MacTex的网站上也写了升级Yosemite有这个问题。升级有些小问题是可以预见的，但很少有像EI Capitan这么多的问题。&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://www.macworld.com/article/2987277/operating-systems/os-x-el-capitan-review-mac-upgrade-thats-as-solid-as-a-rock.html&#34;&gt;Macworld EI Capitan review&lt;/a&gt;文章中有人这样评论：&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;haha nice review ! did you tried the update ?? slow connection safari
freezes on launch outlook crash printer does not work anymore great
job from Apple . My confidence in Apple has been seriously dented!&lt;/p&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>Comparison of clusterProfiler and GSEA-P</title>
      <link>https://guangchuangyu.github.io/2015/11/comparison-of-clusterprofiler-and-gsea-p/</link>
      <pubDate>Mon, 02 Nov 2015 11:50:29 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/11/comparison-of-clusterprofiler-and-gsea-p/</guid>
      <description>&lt;p&gt;Thanks &lt;a href=&#34;https://github.com/mevers&#34;&gt;@mevers&lt;/a&gt; for raising &lt;a href=&#34;https://github.com/GuangchuangYu/clusterProfiler/issues/31&#34;&gt;the issue&lt;/a&gt; to me
and his efforts in benchmarking
&lt;a href=&#34;https://github.com/GuangchuangYu/clusterProfiler&#34;&gt;clusterProfiler&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;He pointed out two issues:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;outputs from gseGO and GSEA-P are poorly overlap.&lt;/li&gt;
&lt;li&gt;pvalues from gseGO are generally smaller and don&amp;rsquo;t show a lot of
variation&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;For GSEA analysis, we have two inputs, a ranked gene list and gene set
collections.&lt;/p&gt;
&lt;p&gt;First of all, the gene set collections are very different. The GMT file
used in his test is &lt;em&gt;c5.cc.v5.0.symbols.gmt&lt;/em&gt;, which is a tiny subset of
GO CC, while clusterProfiler used the whole GO CC corpus.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>use simplify to remove redundancy of enriched GO terms</title>
      <link>https://guangchuangyu.github.io/2015/10/use-simplify-to-remove-redundancy-of-enriched-go-terms/</link>
      <pubDate>Wed, 21 Oct 2015 09:37:11 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/10/use-simplify-to-remove-redundancy-of-enriched-go-terms/</guid>
      <description>&lt;p&gt;To simplify enriched GO result, we can use slim version of GO and use
&lt;em&gt;&lt;a href=&#34;http://guangchuangyu.github.io/2015/05/use-clusterprofiler-as-an-universal-enrichment-analysis-tool/&#34;&gt;enricher&lt;/a&gt;&lt;/em&gt;
function to analyze.&lt;/p&gt;
&lt;p&gt;Another strategy is to use
&lt;a href=&#34;http://www.bioconductor.org/packages/GOSemSim&#34;&gt;GOSemSim&lt;/a&gt; to calculate
similarity of GO terms and remove those highly similar terms by keeping
one representative term. To make this feature available to
&lt;a href=&#34;http://www.bioconductor.org/packages/clusterProfiler&#34;&gt;clusterProfiler&lt;/a&gt;
users, I develop a &lt;em&gt;simplify&lt;/em&gt; method to reduce redundant GO terms from
output of &lt;em&gt;enrichGO&lt;/em&gt; function.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;require(clusterProfiler)
data(geneList, package=&amp;quot;DOSE&amp;quot;)
de &amp;lt;- names(geneList)[abs(geneList) &amp;gt; 2]
bp &amp;lt;- enrichGO(de, ont=&amp;quot;BP&amp;quot;)
enrichMap(bp)
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>[Bioc 32] NEWS of my BioC packages</title>
      <link>https://guangchuangyu.github.io/2015/10/bioc-32-news-of-my-bioc-packages/</link>
      <pubDate>Thu, 15 Oct 2015 16:13:57 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/10/bioc-32-news-of-my-bioc-packages/</guid>
      <description>&lt;p&gt;In BioC 3.2 release, all my packages including
&lt;a href=&#34;http://www.bioconductor.org/packages/GOSemSim&#34;&gt;GOSemSim&lt;/a&gt;,
&lt;a href=&#34;http://www.bioconductor.org/packages/clusterProfiler&#34;&gt;clusterProfiler&lt;/a&gt;,
&lt;a href=&#34;http://www.bioconductor.org/packages/release/bioc/html/DOSE.html&#34;&gt;DOSE&lt;/a&gt;,
&lt;a href=&#34;http://www.bioconductor.org/packages/release/bioc/html/ReactomePA.html&#34;&gt;ReactomePA&lt;/a&gt;,
and &lt;a href=&#34;http://www.bioconductor.org/packages/ChIPseeker&#34;&gt;ChIPseeker&lt;/a&gt; switch
from Sweave to R Markdown for package vignettes.&lt;/p&gt;
&lt;h3 id=&#34;gosemsim&#34;&gt;GOSemSim&lt;/h3&gt;
&lt;p&gt;To make it consistent between
&lt;a href=&#34;http://www.bioconductor.org/packages/GOSemSim&#34;&gt;GOSemSim&lt;/a&gt; and
&lt;a href=&#34;http://www.bioconductor.org/packages/clusterProfiler&#34;&gt;clusterProfiler&lt;/a&gt;,
&amp;lsquo;worm&amp;rsquo; was deprecated and instead we should use &amp;lsquo;celegans&amp;rsquo;. As usual,
information content data was updated.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ChIPseq data mining with ChIPseeker</title>
      <link>https://guangchuangyu.github.io/2015/10/chipseq-data-mining-with-chipseeker/</link>
      <pubDate>Thu, 01 Oct 2015 09:08:06 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/10/chipseq-data-mining-with-chipseeker/</guid>
      <description>&lt;p&gt;ChIP-seq is rapidly becoming a common technique and there are a large
number of dataset available in the public domain. Results from
individual experiments provide a limited understanding of chromatin
interactions, as there is many factors cooperate to regulate
transcription. Unlike other tools that designed for single dataset,
&lt;a href=&#34;http://www.bioconductor.org/packages/ChIPseeker&#34;&gt;ChIPseeker&lt;/a&gt; is
designed for comparing profiles of ChIP-seq datasets at different
levels.&lt;/p&gt;
&lt;p&gt;We provide functions to compare profiles of peaks binding to TSS
regions, annotation, and enriched functional profiles. More importantly,
ChIPseeker incorporates statistical testing of co-occurrence of
different ChIP-seq datasets and can be used to identify co-factors.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>subsetting data in ggtree</title>
      <link>https://guangchuangyu.github.io/2015/09/subsetting-data-in-ggtree/</link>
      <pubDate>Thu, 24 Sep 2015 01:20:21 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/09/subsetting-data-in-ggtree/</guid>
      <description>&lt;p&gt;Subsetting is commonly used in ggtree as we would like to for example
separating internal nodes from tips. We may also want to display
annotation to specific node(s)/tip(s).&lt;/p&gt;
&lt;p&gt;Some software may stored clade information (e.g. bootstrap value) as
internal node labels. Indeed we want to manipulate such information and
taxa labels separately.&lt;/p&gt;
&lt;p&gt;In current ggplot2 (version=1.0.1, access date:2015-09-23), it support
&lt;em&gt;subset&lt;/em&gt;. For instance:&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>通过VNC连接Linux远程桌面</title>
      <link>https://guangchuangyu.github.io/2015/09/linux-remote-desktop-via-vnc/</link>
      <pubDate>Tue, 15 Sep 2015 05:44:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/09/linux-remote-desktop-via-vnc/</guid>
      <description>&lt;p&gt;对于Unix-like系统，远程桌面实在太容易，通过ssh隧道，只要加-X参数即可，如果网速较慢，可以加-C参数，对图像进行压缩。&lt;a href=&#34;http://guangchuangyu.github.io/cn/2013/11/run-remote-r-in-emacs-with-ess/&#34;&gt;ESS都支持通过这个方法把R命令发送到服务器端执行&lt;/a&gt;。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>comic phylogenetic tree with ggtree and comicR</title>
      <link>https://guangchuangyu.github.io/2015/09/comic-phylogenetic-tree-with-ggtree-and-comicr/</link>
      <pubDate>Tue, 08 Sep 2015 01:15:26 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/09/comic-phylogenetic-tree-with-ggtree-and-comicr/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://www.bioconductor.org/packages/release/bioc/html/ggtree.html&#34;&gt;ggtree&lt;/a&gt;
applies the concepts of grammar of graphic in phylogenetic tree
presentation and make it easy to add multiple layers of text and even
figures above a 🌲.&lt;/p&gt;
&lt;p&gt;Here, I cartoonize a phylogenetic tree generated by
&lt;a href=&#34;http://www.bioconductor.org/packages/release/bioc/html/ggtree.html&#34;&gt;ggtree&lt;/a&gt;
with &lt;a href=&#34;https://github.com/timelyportfolio/comicR&#34;&gt;comicR&lt;/a&gt;, which is a
funny package to generate comic (xkcd-like) graph in R. Have fun with
&lt;a href=&#34;http://www.bioconductor.org/packages/release/bioc/html/ggtree.html&#34;&gt;ggtree&lt;/a&gt;
and &lt;a href=&#34;https://github.com/timelyportfolio/comicR&#34;&gt;comicR&lt;/a&gt;.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>subview</title>
      <link>https://guangchuangyu.github.io/2015/08/subview/</link>
      <pubDate>Mon, 31 Aug 2015 03:17:48 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/08/subview/</guid>
      <description>&lt;p&gt;I implemented a function, &lt;em&gt;subview&lt;/em&gt;, in
&lt;a href=&#34;http://www.bioconductor.org/packages/release/bioc/html/ggtree.html&#34;&gt;ggtree&lt;/a&gt;
that make it easy to embed a subplot in ggplot.&lt;/p&gt;
&lt;p&gt;An example is shown below:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;library(ggplot2)
library(ggtree)

dd &amp;lt;- data.frame(x=LETTERS[1:3], y=1:3)
pie &amp;lt;- ggplot(dd, aes(x=1, y, fill=x)) + 
	geom_bar(stat=&amp;quot;identity&amp;quot;, width=1) + 
	coord_polar(theta=&amp;quot;y&amp;quot;) + theme_tree() + 
	xlab(NULL) + ylab(NULL) + 
	theme_transparent()

x &amp;lt;- sample(2:9)
y &amp;lt;- sample(2:9)
width &amp;lt;- sample(seq(0.05, 0.15, length.out=length(x)))
height &amp;lt;- width

p &amp;lt;- ggplot(data=data.frame(x=c(0, 10), y=c(0, 10)), aes(x, y))+geom_blank()
print(p)
for (i in seq_along(x)) {
	p %&amp;lt;&amp;gt;% subview(pie, x[i], y[i], width[i], height[i])
	print(p)
}
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>functional enrichment analysis with NGS data</title>
      <link>https://guangchuangyu.github.io/2015/08/functional-enrichment-analysis-with-ngs-data/</link>
      <pubDate>Fri, 21 Aug 2015 03:22:21 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/08/functional-enrichment-analysis-with-ngs-data/</guid>
      <description>&lt;p&gt;I found a Bioconductor package,
&lt;a href=&#34;http://www.bioconductor.org/packages/seq2pathway/&#34;&gt;seq2pathway&lt;/a&gt;, that
can apply functional analysis to NGS data. It consists of two
components, &lt;em&gt;seq2gene&lt;/em&gt; and &lt;em&gt;gene2pathway&lt;/em&gt;. &lt;em&gt;seq2gene&lt;/em&gt; converts genomic
coordination to genes while &lt;em&gt;gene2pathway&lt;/em&gt; performs functional analysis
at gene level.&lt;/p&gt;
&lt;p&gt;I think it would be interesting to incorporate &lt;em&gt;seq2gene&lt;/em&gt; with
clusterProfiler. But it fail to run due to it call absolute path of
python installed in the author&amp;rsquo;s computer.
&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/Bioconductor/others/Screenshot%202015-08-20%2015.25.52.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>functional enrichment for GTEx paper</title>
      <link>https://guangchuangyu.github.io/2015/08/functional-enrichment-for-gtex-paper/</link>
      <pubDate>Thu, 13 Aug 2015 05:44:27 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/08/functional-enrichment-for-gtex-paper/</guid>
      <description>&lt;p&gt;The ENCODE consortium has recently published &lt;a href=&#34;http://www.ncbi.nlm.nih.gov/pubmed/25954002&#34;&gt;a great paper&lt;/a&gt; on Gene Expression
from the GTEx dataset. A criticism raised on
&lt;a href=&#34;https://pubpeer.com/publications/EB99BD086B27075CFF5278F1CEAA57&#34;&gt;pubpeer&lt;/a&gt;
is that the gene ontology enrichment analysis was done with DAVID which
has not been updated in the last five years.&lt;/p&gt;
&lt;p&gt;The result is shown below:
&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/Bioconductor/clusterProfiler/Screenshot%202015-07-15%2019.49.01.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>递归</title>
      <link>https://guangchuangyu.github.io/2015/08/recursive/</link>
      <pubDate>Tue, 11 Aug 2015 09:12:14 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/08/recursive/</guid>
      <description>&lt;p&gt;递归正如‘盗梦空间’中的场景：
&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/2015/recursive_image.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;PS: 使用《&lt;a href=&#34;https://mp.weixin.qq.com/s/CP00v7HuclUcfJn2_aSplA&#34;&gt;windows用户, 截屏新手段&lt;/a&gt;》可以一句for循环生成类似这种效果的图。&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;简言之就是不断调用自己，
&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/2015/recursive.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;经常我们会拿fibonacci数来讲解递归，正如在&lt;a href=&#34;http://guangchuangyu.github.io/2013/04/rabbits-and-recurrence-relations/&#34;&gt;Rabbits and Recurrence
Relations&lt;/a&gt;一题中所实现的，我使用了静态变量来缓存，以加快运行速度。R版本的实现可以参考&lt;a href=&#34;http://guangchuangyu.github.io/2012/07/tricky-things-in-r/&#34;&gt;tricky things in R&lt;/a&gt;一文，相对应于C的静态变量，在R中使用了局部的全局变量，这需要用&lt;code&gt;&amp;lt;&amp;lt;-&lt;/code&gt;来赋值。&lt;/p&gt;
&lt;p&gt;在开发ggtree时，unrooted layout最早的版本就是使用递归实现，但&lt;code&gt;BiocCheck&lt;/code&gt;会把&lt;code&gt;&amp;lt;&amp;lt;-&lt;/code&gt;报出来，而Bioconductor的人不喜欢看到这个赋值符，于是我改成了现在的版本，使用for loop。递归和循环一样，都只是程序的一种控制机制，某些递归实现代码非常短的同时，可读性非常强。&lt;/p&gt;
&lt;h4 id=&#34;example-1&#34;&gt;Example 1&lt;/h4&gt;
&lt;p&gt;比如我们要写writeSequence这样的函数：&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;Call                    Output
writeSequence(1);   1
writeSequence(2);   1 1
writeSequence(3);   2 1 2
writeSequence(4);   2 1 1 2
writeSequence(5);   3 2 1 2 3
writeSequence(6);   3 2 1 1 2 3
&lt;/code&gt;&lt;/pre&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-java&#34; data-lang=&#34;java&#34;&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;public&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;void&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;writeSequence&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;int&lt;/span&gt; n&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;{&lt;/span&gt;
    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;n &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;&lt;/span&gt; 1&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;
    &lt;span style=&#34;color:#66d9ef&#34;&gt;throw&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;new&lt;/span&gt; IllegalArgumentException&lt;span style=&#34;color:#f92672&#34;&gt;();&lt;/span&gt;

    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;n &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; 1&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;{&lt;/span&gt;
    System&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;out&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;print&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;1&lt;span style=&#34;color:#f92672&#34;&gt;);&lt;/span&gt;
    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;;&lt;/span&gt;
    &lt;span style=&#34;color:#f92672&#34;&gt;}&lt;/span&gt;

    &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;n &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; 2&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;{&lt;/span&gt;
    System&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;out&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;print&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;1 1&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;);&lt;/span&gt;
    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;;&lt;/span&gt;
    &lt;span style=&#34;color:#f92672&#34;&gt;}&lt;/span&gt;

    &lt;span style=&#34;color:#66d9ef&#34;&gt;int&lt;/span&gt; x &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;int&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt; Math&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;ceil&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;n&lt;span style=&#34;color:#f92672&#34;&gt;/&lt;/span&gt;2&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;0&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;);&lt;/span&gt;
    
    System&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;out&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;print&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;x &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; &amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;);&lt;/span&gt;
    writeSequence&lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;n&lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt;2&lt;span style=&#34;color:#f92672&#34;&gt;);&lt;/span&gt;
    System&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;out&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;print&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34; &amp;#34;&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;+&lt;/span&gt; x&lt;span style=&#34;color:#f92672&#34;&gt;);&lt;/span&gt;
&lt;span style=&#34;color:#f92672&#34;&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>parsing BED coordinates</title>
      <link>https://guangchuangyu.github.io/2015/08/parsing-bed-coordinates/</link>
      <pubDate>Fri, 07 Aug 2015 03:03:08 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/08/parsing-bed-coordinates/</guid>
      <description>&lt;p&gt;In &lt;a href=&#34;http://bioinformatics.oxfordjournals.org/content/suppl/2015/03/11/btv145.DC1/TSS_annotation_comparision.pdf&#34;&gt;supplemental file&lt;/a&gt;
of ChIPseeker &lt;a href=&#34;http://doi.org/10.1093/bioinformatics/btv145&#34;&gt;paper&lt;/a&gt;, I
compare distances to TSS reported by several ChIP annotation software,
including &lt;a href=&#34;http://www.bioconductor.org/packages/ChIPseeker&#34;&gt;ChIPseeker&lt;/a&gt;,
&lt;a href=&#34;http://www.bioconductor.org/packages/ChIPpeakAnno&#34;&gt;ChIPpeakAnno&lt;/a&gt;,
&lt;a href=&#34;http://homer.salk.edu/homer/chipseq/&#34;&gt;HOMER&lt;/a&gt; and
&lt;a href=&#34;http://www.bioinformatics.org/peakanalyzer/wiki/&#34;&gt;PeakAnalyzer&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Although I found that the chromStart positions in HOMER output have a +1
shift compare to other software, I did not realize this issue since all
other software are consistent.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggtree annotate phylogenetic tree with local images</title>
      <link>https://guangchuangyu.github.io/2015/08/ggtree-annotate-phylogenetic-tree-with-local-images/</link>
      <pubDate>Sat, 01 Aug 2015 12:52:34 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/08/ggtree-annotate-phylogenetic-tree-with-local-images/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/Bioconductor/ggtree/annotation_image/Screenshot%202015-08-01%2020.53.50.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;In &lt;a href=&#34;http://www.bioconductor.org/packages/release/bioc/html/ggtree.html&#34;&gt;ggtree&lt;/a&gt;,
we provide a function &lt;em&gt;annotation_image&lt;/em&gt; for annotating phylogenetic
tree with images.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>upsetplot in ChIPseeker</title>
      <link>https://guangchuangyu.github.io/2015/07/upsetplot-in-chipseeker/</link>
      <pubDate>Tue, 28 Jul 2015 06:45:01 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/07/upsetplot-in-chipseeker/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://guangchuangyu.github.io/2015/07/chipseeker-an-r/bioconductor-package-for-chip-peak-annotation-comparison-and-visualization/&#34;&gt;ChIPseeker&lt;/a&gt;
is an R package for ChIP peak annotation, comparison and visualization.&lt;/p&gt;
&lt;p&gt;We have implemented &lt;a href=&#34;http://guangchuangyu.github.io/2014/04/visualization-methods-in-chipseeker/&#34;&gt;several visualization methods&lt;/a&gt;,
including
&lt;em&gt;&lt;a href=&#34;http://guangchuangyu.github.io/2014/10/multiple-annotation-in-chipseeker/&#34;&gt;vennpie&lt;/a&gt;&lt;/em&gt;
that was designed for viewing annotation overlap as shown below:&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Macbook Pro 双系统记</title>
      <link>https://guangchuangyu.github.io/2015/07/macbook-dual-boot/</link>
      <pubDate>Fri, 24 Jul 2015 17:44:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/07/macbook-dual-boot/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://guangchuangyu.github.io/cn/2011/06/screen-shot/&#34;&gt;11年的老机器&lt;/a&gt;，闲置了两年，终于在我来HKU的时候发挥了作用，我第一次遇到做生物信息学要自己背电脑去干活。于是每天学校宿舍两头背，当时&lt;/p&gt;
&lt;p&gt;唯一的问题是headphone亮着红光，这个本身不难解决，用alsamixer把S/PDIF给mute了就OK了，但坑爹的是每次启动都是亮着红光，这让我很是纠结，我只能通过rc.local，让它每次开机都把alsamixer的状态都给恢复一下：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>flip and rotate branches in ggtree</title>
      <link>https://guangchuangyu.github.io/2015/07/flip-and-rotate-branches-in-ggtree/</link>
      <pubDate>Wed, 01 Jul 2015 02:51:34 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/07/flip-and-rotate-branches-in-ggtree/</guid>
      <description>&lt;p&gt;&lt;em&gt;&lt;strong&gt;flip&lt;/strong&gt;&lt;/em&gt; function is a feature request from ggtree user. It accepts a
tree view and two node numbers and exchange the positions of the
selected clades.&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;require(ggtree)
set.seed(2015-07-01)
tr &amp;lt;- rtree(30)
p &amp;lt;- ggtree(tr) + geom_text(aes(label=node))
gridExtra::grid.arrange(p, flip(p, 38, 33), ncol=2)
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>安装Amos</title>
      <link>https://guangchuangyu.github.io/2015/06/install-amos/</link>
      <pubDate>Tue, 23 Jun 2015 07:46:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/06/install-amos/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://sourceforge.net/projects/amos/?source=navbar&#34;&gt;Amos&lt;/a&gt;是纯于比较难安装那种，因为依赖关系比较复杂。&lt;/p&gt;
&lt;p&gt;首先编译需要&lt;code&gt;qt4-dev&lt;/code&gt;和&lt;code&gt;boost graph toolkit&lt;/code&gt;：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;sudo apt-get install libqt4-dev
sudo apt-get install libboost-graph-dev
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;再者是&lt;code&gt;perl&lt;/code&gt;模块：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;sudo cpan -i DBI
sudo cpan -i Statistics::Descriptive
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>dotplot for enrichment result</title>
      <link>https://guangchuangyu.github.io/2015/06/dotplot-for-enrichment-result/</link>
      <pubDate>Tue, 23 Jun 2015 05:37:09 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/06/dotplot-for-enrichment-result/</guid>
      <description>&lt;p&gt;This is a feature request from &lt;a href=&#34;http://www.bioconductor.org/packages/release/bioc/html/clusterProfiler.html&#34;&gt;clusterProfiler&lt;/a&gt;
user. It&amp;rsquo;s similar to what I implemented in
&lt;a href=&#34;http://www.bioconductor.org/packages/release/bioc/html/clusterProfiler.html&#34;&gt;clusterProfiler&lt;/a&gt;
for comparing biological themes. For comparing different enrichment
results, the x-axis represent different gene clusters while for a single
enrichment result, the x-axis can be gene count or gene ratio. This is
actually similar to traditional barplot, with dot position as bar height
and dot color as bar color. But dotplot can represent one more feature
nicely by dot size and it can be a good alternative to barplot.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggtree with funny fonts</title>
      <link>https://guangchuangyu.github.io/2015/06/ggtree-with-funny-fonts/</link>
      <pubDate>Fri, 12 Jun 2015 06:19:56 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/06/ggtree-with-funny-fonts/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://cran.r-project.org/web/packages/showtext/index.html&#34;&gt;showtext&lt;/a&gt;
is a neat solution to use various types of fonts in R graphs and make it
easy to use funny fonts. With
&lt;a href=&#34;http://cran.r-project.org/web/packages/showtext/index.html&#34;&gt;showtext&lt;/a&gt;,
we can draw phylogenetic tree with different types of fonts even with
symbolic/icon fonts.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;require(showtext)

font.add.google(&amp;quot;Gochi Hand&amp;quot;, &amp;quot;gochi&amp;quot;)
font.add.google(&amp;quot;Rock Salt&amp;quot;, &amp;quot;rock&amp;quot;)

link = &amp;quot;http://img.dafont.com/dl/?f=wm_people_1&amp;quot;;
download.file(link, &amp;quot;wmpeople1.zip&amp;quot;, mode = &amp;quot;wb&amp;quot;);
unzip(&amp;quot;wmpeople1.zip&amp;quot;);
font.add(&amp;quot;wmpeople1&amp;quot;, &amp;quot;wmpeople1.TTF&amp;quot;);

link = &amp;quot;http://img.dafont.com/dl/?f=emoticons&amp;quot;;
download.file(link, &amp;quot;emoticons.zip&amp;quot;, mode = &amp;quot;wb&amp;quot;);
unzip(&amp;quot;emoticons.zip&amp;quot;);
font.add(&amp;quot;emoticons&amp;quot;, &amp;quot;emoticons.ttf&amp;quot;);


showtext.auto()
set.seed(2015-05-14)

library(ggplot2)
library(ggtree)

tree &amp;lt;- rtree(30)
ggtree(tree, color=&amp;quot;darkgreen&amp;quot;) + geom_tiplab(family=&amp;quot;gochi&amp;quot;) + theme_classic() +
theme(axis.text.x=element_text(size=rel(4), family=&amp;quot;emoticons&amp;quot;, color=&amp;quot;firebrick&amp;quot;)) +
scale_y_continuous(breaks=seq(0, 30, 4), labels=letters[c(12:17, 20, 21)]) +
theme(axis.text.y=element_text(size=rel(4), family=&amp;quot;wmpeople1&amp;quot;, color=&amp;quot;#FDAC4F&amp;quot;)) +
annotate(&amp;quot;text&amp;quot;, x=2, y=18, label=&amp;quot;Have fun with ggtree!&amp;quot;,
family=&amp;quot;rock&amp;quot;, angle=30, size=12, color=&amp;quot;steelblue&amp;quot;)
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>BMC favors source code plagiarism</title>
      <link>https://guangchuangyu.github.io/2015/05/bmc-favors-source-code-plagiarism/</link>
      <pubDate>Wed, 27 May 2015 13:38:44 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/05/bmc-favors-source-code-plagiarism/</guid>
      <description>&lt;p&gt;I found source code plagiarism a year ago and reported this case to &lt;a href=&#34;http://www.biomedcentral.com/bmcsystbiol&#34;&gt;BMC Systems Biology&lt;/a&gt;:&lt;/p&gt;
&lt;p&gt;![](&lt;a href=&#34;http://guangchuangyu.github.io/blog_images/2015/plagiarism/Screenshot&#34;&gt;http://guangchuangyu.github.io/blog_images/2015/plagiarism/Screenshot&lt;/a&gt; 2015-05-27 19.56.58.png)&lt;/p&gt;
&lt;p&gt;I listed source code of many functions that are exactly copied from
&lt;a href=&#34;http://www.bioconductor.org/packages/release/bioc/html/GOSemSim.html&#34;&gt;GOSemSim&lt;/a&gt;
with only function name changed in my email. The detail of source code
plagiarism can also be found at &lt;strong&gt;&lt;a href=&#34;http://guangchuangyu.github.io/2014/11/proper-use-of-gosemsim/&#34;&gt;Proper use of
GOSemSim&lt;/a&gt;&lt;/strong&gt;.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>如何画类似MEME的注释序列</title>
      <link>https://guangchuangyu.github.io/2015/05/draw-meme-like-figure/</link>
      <pubDate>Thu, 21 May 2015 14:53:35 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/05/draw-meme-like-figure/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/2015/Screenshot%202015-05-21%2010.31.46.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://meme-suite.org&#34;&gt;MEME&lt;/a&gt;是motif分析的webserver，所谓的注释序列就是一条线条上画一些长方形的box。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>BMC Favor Plagiarism</title>
      <link>https://guangchuangyu.github.io/2015/05/bmc-favor-plagiarism/</link>
      <pubDate>Sun, 17 May 2015 21:51:43 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/05/bmc-favor-plagiarism/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://cran.r-project.org/web/packages/ppiPre/index.html&#34;&gt;ppiPre&lt;/a&gt;抄袭了&lt;a href=&#34;https://github.com/GuangchuangYu/GOSemSim&#34;&gt;GOSemSim&lt;/a&gt;的代码，证据当然非常充分，比对一下代码就知道了，我在&lt;a href=&#34;http://guangchuangyu.github.io/2014/11/proper-use-of-gosemsim/&#34;&gt;Proper use of GOSemSim&lt;/a&gt;一文中，做出了一些比较，另外也可以参考&lt;a href=&#34;https://github.com/cran/ppiPre/commit/c267700ca09a599dab77326959a0aa6a2980ceed&#34;&gt;github&lt;/a&gt;页面，github记录了ppiPre被暴光抄袭之后所做的修改。
从我给BMC Systems Biology的编辑反馈这件事开始，在这铁板钉钉的事实面前，编辑拖了整整一年，而这一年时间过去了，ppiPre仍没有被编辑部受理。从最早反应这件事情，编辑信誓旦旦说他们很重视这种事情，到后面对我的邮件视而不见，我愿意相信编辑部处理这些事情，需要时间，他们有自己的规则，但一年的时间，不回邮件，冷处理以淡化此事，这绝对不是应该有的规则。 在编辑一直无视我的情况下，我写出了&lt;a href=&#34;http://guangchuangyu.github.io/2014/11/proper-use-of-gosemsim/&#34;&gt;Proper use of GOSemSim&lt;/a&gt;一文，列举了一些一模一样的代码，并告知CRAN，当ppiPre被CRAN移除时，我写信给编辑，这时候，编辑告诉我说他们准备要去联系作者了，这时候已经过去半年了，是的！你没有看错，半年过去了，编辑说他们还没去联系作者！我是不相信的。必然是联系了之后，有某些不为人知的原因，所以编辑态度反常，对抄袭这种打鸡血的事情，不断在打太极。&lt;/p&gt;
&lt;p&gt;再过二个月，ppiPre的作者&lt;a href=&#34;http://web.xidian.edu.cn/dengyue/&#34;&gt;邓岳&lt;/a&gt;给我写了信：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>use clusterProfiler as an universal enrichment analysis tool</title>
      <link>https://guangchuangyu.github.io/2015/05/use-clusterprofiler-as-an-universal-enrichment-analysis-tool/</link>
      <pubDate>Mon, 11 May 2015 08:32:04 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/05/use-clusterprofiler-as-an-universal-enrichment-analysis-tool/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://www.bioconductor.org/packages/release/bioc/html/clusterProfiler.html&#34;&gt;clusterProfiler&lt;/a&gt;
supports enrichment analysis of both hypergeometric test and gene set
enrichment analysis. It internally supports &lt;a href=&#34;http://geneontology.org/&#34;&gt;Gene Ontology&lt;/a&gt; analysis of about 20 species, &lt;a href=&#34;http://www.genome.jp/kegg/&#34;&gt;Kyoto Encyclopedia of Genes and Genomes (KEGG)&lt;/a&gt;
with all species that have annotation available in KEGG database, &lt;a href=&#34;http://david.abcc.ncifcrf.gov/summary.jsp&#34;&gt;DAVID annotation&lt;/a&gt; (only
hypergeometric test supported), &lt;a href=&#34;http://disease-ontology.org/&#34;&gt;Disease Ontology&lt;/a&gt; and &lt;a href=&#34;http://ncg.kcl.ac.uk/&#34;&gt;Network of Cancer Genes&lt;/a&gt; (via
&lt;a href=&#34;http://www.bioconductor.org/packages/release/bioc/html/DOSE.html&#34;&gt;DOSE&lt;/a&gt;
for human) and &lt;a href=&#34;http://www.reactome.org/&#34;&gt;Reactome Pathway&lt;/a&gt; (via
&lt;a href=&#34;http://www.bioconductor.org/packages/release/bioc/html/ReactomePA.html&#34;&gt;ReactomePA&lt;/a&gt;
for several species). This is still not enough for users may want to
analyze their data with unsupported organisms, &lt;a href=&#34;http://geneontology.org/page/go-slim-and-subset-guide&#34;&gt;slim version of
GO&lt;/a&gt;, novel
functional annotation (eg GO via &lt;a href=&#34;https://www.blast2go.com/&#34;&gt;blastgo&lt;/a&gt;
and KEGG via &lt;a href=&#34;http://www.genome.jp/tools/kaas/&#34;&gt;KAAS&lt;/a&gt;), unsupported
ontology/pathway or customized annotation.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://www.bioconductor.org/packages/release/bioc/html/clusterProfiler.html&#34;&gt;clusterProfiler&lt;/a&gt;
provides &lt;em&gt;enricher&lt;/em&gt; function for hypergeometric test and &lt;em&gt;GSEA&lt;/em&gt; function
for gene set enrichment analysis that are designed to accept user
defined annotation. They accept two additional parameters TERM2GENE and
TERM2NAME. As indicated in the parameter names, TERM2GENE is a
data.frame with first column of term ID and second column of
corresponding mapped gene and TERM2NAME is a data.frame with first
column of term ID and second column of corresponding term name.
TERM2NAME is optional.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>using GOSemSim to rank proteins obtained by co-IP</title>
      <link>https://guangchuangyu.github.io/2015/05/using-gosemsim-to-rank-proteins-obtained-by-co-ip/</link>
      <pubDate>Mon, 04 May 2015 10:57:15 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/05/using-gosemsim-to-rank-proteins-obtained-by-co-ip/</guid>
      <description>&lt;p&gt;Co-IP is usually used to identified interactions among specific
proteins. It is widely used in detecting protein complex. Unfortunately,
an identified protein may not be an interactor, and sometimes can be a
background contaminant. Ranking proteins can help us to focus a study on
a few high quality candidates for subsequent interaction investigation.
My R package &lt;a href=&#34;https://github.com/GuangchuangYu/GOSemSim&#34;&gt;GOSemSim&lt;/a&gt; has
been used in many studies to investigate protein protein interaction,
see &lt;a href=&#34;http://pubs.rsc.org/en/content/articlehtml/2014/mb/c3mb70486f&#34;&gt;1&lt;/a&gt;,
&lt;a href=&#34;http://www.sciencedirect.com/science/article/pii/S1874391915000937&#34;&gt;2&lt;/a&gt;,
&lt;a href=&#34;http://www.sciencedirect.com/science/article/pii/S1476927115000493&#34;&gt;3&lt;/a&gt;,
&lt;a href=&#34;http://www.mcponline.org/content/13/5/1318.short&#34;&gt;4&lt;/a&gt; and
&lt;a href=&#34;http://scholar.google.com/scholar?oi=bibs&amp;amp;hl=en&amp;amp;cites=9484177541993722322,16048119560581430155,18126401808149291947&#34;&gt;more&lt;/a&gt;.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>[Bioc 31] NEWS of my BioC packages</title>
      <link>https://guangchuangyu.github.io/2015/04/bioc-31-news-of-my-bioc-packages/</link>
      <pubDate>Mon, 20 Apr 2015 11:44:01 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/04/bioc-31-news-of-my-bioc-packages/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2015/Screenshot%202015-03-12%2019.05.54.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;h3 id=&#34;gosemsim&#34;&gt;GOSemSim&lt;/h3&gt;
&lt;p&gt;&lt;a href=&#34;www.bioconductor.org/packages/release/bioc/html/GOSemSim.html&#34;&gt;GOSemSim&lt;/a&gt;
was first implemented in &lt;a href=&#34;http://guangchuangyu.github.io/2008/08/gosemsim/&#34;&gt;2008&lt;/a&gt;
and published in
&lt;a href=&#34;http://bioinformatics.oxfordjournals.org/content/26/7/976&#34;&gt;Bioinformatics&lt;/a&gt;
in 2010. It&amp;rsquo;s now a mature package with no bugs found in the past half
year. Only vignette and Information content data were updated.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/Bioconductor/GOSemSim/gosemsim_stats.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>an example of drawing beast tree using ggtree</title>
      <link>https://guangchuangyu.github.io/2015/04/an-example-of-drawing-beast-tree-using-ggtree/</link>
      <pubDate>Wed, 01 Apr 2015 01:50:04 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/04/an-example-of-drawing-beast-tree-using-ggtree/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://beast.bio.ed.ac.uk/figtree&#34;&gt;FigTree&lt;/a&gt; is designed for viewing
beast output as demonstrated by their example data:
&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2015/Screenshot%202015-03-10%2018.15.57.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>DAVID functional analysis with clusterProfiler</title>
      <link>https://guangchuangyu.github.io/2015/03/david-functional-analysis-with-clusterprofiler/</link>
      <pubDate>Mon, 16 Mar 2015 06:33:34 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/03/david-functional-analysis-with-clusterprofiler/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://github.com/GuangchuangYu/clusterProfiler&#34;&gt;clusterProfiler&lt;/a&gt; was
used to visualize &lt;a href=&#34;http://david.abcc.ncifcrf.gov/summary.jsp&#34;&gt;DAVID&lt;/a&gt;
results in a paper published in &lt;a href=&#34;http://www.ncbi.nlm.nih.gov/pmc/articles/PMC3907017/&#34;&gt;BMC
Genomics&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2015/clusterProfiler_david.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;Some users told me that they may want to use DAVID at some
circumstances. I think it maybe a good idea to make clusterProfiler
supports DAVID, so that
&lt;a href=&#34;http://david.abcc.ncifcrf.gov/summary.jsp&#34;&gt;DAVID&lt;/a&gt; users can use
visualization functions provided by
&lt;a href=&#34;https://github.com/GuangchuangYu/clusterProfiler&#34;&gt;clusterProfiler&lt;/a&gt;.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;require(DOSE)
require(clusterProfiler)
data(geneList)
gene = names(geneList)[abs(geneList) &amp;gt; 2]
david = enrichDAVID(gene = gene, idType=&amp;quot;ENTREZ_GENE_ID&amp;quot;, 
listType=&amp;quot;Gene&amp;quot;, annotation=&amp;quot;KEGG_PATHWAY&amp;quot;)



&amp;gt; summary(david)
               ID            Description GeneRatio  BgRatio       pvalue
hsa04110 hsa04110             Cell cycle     11/68 125/5085 4.254437e-06
hsa04114 hsa04114         Oocyte meiosis     10/68 110/5085 1.119764e-05
hsa03320 hsa03320 PPAR signaling pathway      7/68  69/5085 2.606715e-04
             p.adjust qvalue                                             geneID
hsa04110 0.0003998379     NA 9133/4174/890/991/1111/891/7272/8318/4085/983/9232
hsa04114 0.0005261534     NA    9133/5241/51806/3708/991/891/4085/983/9232/6790
hsa03320 0.0081354974     NA                 4312/2167/5346/5105/3158/9370/9415
         Count
hsa04110    11
hsa04114    10
hsa03320     7
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;There are only 5085 human genes annotated by KEGG, this is due to
out-of-date DAVID data.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggtree - updating a tree view</title>
      <link>https://guangchuangyu.github.io/2015/02/ggtree-updating-a-tree-view/</link>
      <pubDate>Tue, 10 Feb 2015 02:58:23 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/02/ggtree-updating-a-tree-view/</guid>
      <description>&lt;p&gt;I am very exciting that I have received very positive feedback from
&lt;a href=&#34;https://twitter.com/AhmedMoustafa&#34;&gt;Ahmed Moustafa&lt;/a&gt; and &lt;a href=&#34;https://twitter.com/sdwfrost&#34;&gt;Simon Frost&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2015/Screenshot-2015-02-10-10.27.27.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2015/Screenshot-2015-02-10-10.27.07.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://github.com/GuangchuangYu/ggtree&#34;&gt;ggtree&lt;/a&gt; now has equipped with
a lot of new features. This time, I would like to introduce the replace
operator, &lt;code&gt;%&amp;lt;%&lt;/code&gt;. Suppose we have build a tree view using ggtree with
multiple layers, we don&amp;rsquo;t need to run the code again to build a new tree
view with another tree. In
&lt;a href=&#34;https://github.com/GuangchuangYu/ggtree&#34;&gt;ggtree&lt;/a&gt;, we provides an operator, &lt;code&gt;%&amp;lt;%&lt;/code&gt;, for updating tree view.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>KEGG enrichment analysis with latest online data using clusterProfiler</title>
      <link>https://guangchuangyu.github.io/2015/02/kegg-enrichment-analysis-with-latest-online-data-using-clusterprofiler/</link>
      <pubDate>Sun, 01 Feb 2015 12:38:27 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/02/kegg-enrichment-analysis-with-latest-online-data-using-clusterprofiler/</guid>
      <description>&lt;p&gt;&lt;em&gt;KEGG.db&lt;/em&gt; is not updated since 2012. The data is now pretty old, but
many of the Bioconductor packages still using it for KEGG annotation and
enrichment analysis. As pointed out in &amp;lsquo;&lt;a href=&#34;http://www.acgt.me/blog/2015/1/16/are-there-too-many-biological-databases&#34;&gt;Are there too many biological databases&lt;/a&gt;&amp;rsquo;,
there is a problem that many out of date biological databases often
don&amp;rsquo;t get offline. This issue also exists in web-server or software that
using out-of-date data. For example, the
&lt;a href=&#34;http://wego.genomics.org.cn/cgi-bin/wego/index.pl&#34;&gt;WEGO&lt;/a&gt; web-server
stopped updating GO annotation data since 2009, and WEGO still online
with &lt;a href=&#34;https://scholar.google.com.hk/scholar?as_ylo=2015&amp;amp;hl=en&amp;amp;as_sdt=0,5&amp;amp;sciodt=0,5&amp;amp;cites=13025429171853466135&amp;amp;scipsc=&#34;&gt;many people using it&lt;/a&gt;.
The biological story may changed totally if using a recently updated
data. Seriously, We should keep an eye on this issue.&lt;/p&gt;
&lt;p&gt;Now &lt;em&gt;enrichKEGG&lt;/em&gt; function is reloaded with a new parameter &lt;em&gt;use_internal_data&lt;/em&gt;. This
parameter is by default setting to FALSE, and &lt;em&gt;enrichKEGG&lt;/em&gt; function will
download the latest KEGG data for enrichment analysis. If the parameter
&lt;em&gt;use_internal_data&lt;/em&gt; is explicitly setting to TRUE, it will use the
&lt;em&gt;KEGG.db&lt;/em&gt; which is still supported but not recommended. With this new
feature, supported species is unlimited if only there are KEGG
annotations available in KEGG database. You can access the full list of
species supported by KEGG via:
&lt;a href=&#34;http://www.genome.jp/kegg/catalog/org_list.html&#34;&gt;http://www.genome.jp/kegg/catalog/org_list.html&lt;/a&gt; Now the &lt;em&gt;organism&lt;/em&gt;
parameter in &lt;em&gt;enrichKEGG&lt;/em&gt; should be abbreviation of academic name, for
example &amp;lsquo;hsa&amp;rsquo; for human and &amp;lsquo;mmu&amp;rsquo; for mouse. It accepts any species
listed in &lt;a href=&#34;http://www.genome.jp/kegg/catalog/org_list.html&#34;&gt;http://www.genome.jp/kegg/catalog/org_list.html&lt;/a&gt;. In the
current release version of
&lt;a href=&#34;http://bioconductor.org/packages/3.0/bioc/html/clusterProfiler.html&#34;&gt;clusterProfiler&lt;/a&gt;
(in Bioconductor 3.0), &lt;em&gt;enrichKEGG&lt;/em&gt; supports about 20 species, and the
&lt;em&gt;organism&lt;/em&gt; parameter accept common name of species, for instance &amp;ldquo;human&amp;rdquo;
and &amp;ldquo;mouse&amp;rdquo;. For these previously supported species, common name is also
supported. So that you script is still working with new version of
&lt;a href=&#34;http://bioconductor.org/packages/devel/bioc/html/clusterProfiler.html&#34;&gt;clusterProfiler&lt;/a&gt;.
For other species, common name is not supported, since I don&amp;rsquo;t want to
maintain such a long mapping list with many species have no common name
available and it may also introduce unexpected bugs.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ggtree in Bioconductor 3.1</title>
      <link>https://guangchuangyu.github.io/2015/01/ggtree-in-bioconductor-3.1/</link>
      <pubDate>Mon, 19 Jan 2015 03:50:23 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/01/ggtree-in-bioconductor-3.1/</guid>
      <description>&lt;p&gt;I am very glad that &lt;a href=&#34;http://guangchuangyu.github.io/2014/12/ggtree/&#34;&gt;ggtree&lt;/a&gt; is now
available via Bioconductor. This is my 6th Bioconductor package.
&lt;a href=&#34;http://guangchuangyu.github.io/2014/12/ggtree/&#34;&gt;ggtree&lt;/a&gt; now supports parsing output
files from BEAST, PAML, HYPHY, EPA and PPLACER and can annotate
phylogenetic tree directly using plot methods.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title></title>
      <link>https://guangchuangyu.github.io/2015/01/</link>
      <pubDate>Mon, 05 Jan 2015 07:16:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2015/01/</guid>
      <description>&lt;p&gt;I like running &lt;a href=&#34;http://en.wikipedia.org/wiki/Fortune_%28Unix%29&#34;&gt;fortune&lt;/a&gt; every time when the terminal was started. A &lt;a href=&#34;https://guangchuangyu.github.io/cn/2007/06/screenshot/&#34;&gt;screenshot&lt;/a&gt; is shown below:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2007/06/wmaker.png&#34; alt=&#34;wmaker&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>viewing and annotating phylogenetic tree with ggtree</title>
      <link>https://guangchuangyu.github.io/2014/12/viewing-and-annotating-phylogenetic-tree-with-ggtree/</link>
      <pubDate>Sun, 21 Dec 2014 08:00:08 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/12/viewing-and-annotating-phylogenetic-tree-with-ggtree/</guid>
      <description>&lt;p&gt;When I need to annotate nucleotide substitutions in the phylogenetic
tree, I found that all the software are designed to display the tree but
not annotating it. Some of them may support annotating the tree with
specific data such as bootstrap values, but they are restricted to a few
supported data types. It is hard/impossible to inject user specific
data.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2014/12/2014-12-21-145753_579x436_scrot.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>auto-complete in ESS</title>
      <link>https://guangchuangyu.github.io/2014/12/auto-complete-in-ess/</link>
      <pubDate>Sun, 07 Dec 2014 10:22:35 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/12/auto-complete-in-ess/</guid>
      <description>Auto complete is good, it can save you times in typing and prevent typo sometimes.
RStudio now supports function arguments in auto complete. ESS&amp;rsquo;s auto complete is more advance, it supports help page.
We should use &amp;lsquo;ess-use-auto-complete&amp;rsquo; to activate auto complete in ESS buffers.
(setq ess-use-auto-complete t)The effect is quite amazing. Auto-complete extension is needed for ESS, we need to install the auto-complete extension and load it at Emacs startup.</description>
    </item>
    
    <item>
      <title>proper use of GOSemSim</title>
      <link>https://guangchuangyu.github.io/2014/11/proper-use-of-gosemsim/</link>
      <pubDate>Sun, 23 Nov 2014 02:27:23 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/11/proper-use-of-gosemsim/</guid>
      <description>&lt;p&gt;One day, I am looking for R packages that can analyze PPI and after
searching, I found the
&lt;a href=&#34;http://cran.r-project.org/web/packages/ppiPre/index.html&#34;&gt;ppiPre&lt;/a&gt;
package in CRAN.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2014/11/2014-11-22-215959_895x256_scrot.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>hello yosemite</title>
      <link>https://guangchuangyu.github.io/2014/11/hello-yosemite/</link>
      <pubDate>Fri, 14 Nov 2014 04:34:48 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/11/hello-yosemite/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2014/11/Screenshot-2014-11-11-14.07.45.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;Installing OS is painful, you need to re-install all the software and
configure them to the way you want. We don&amp;rsquo;t want to wast time in doing
this. To prevent doing this dirty job, we perform an upgrade install
instead of clean install. We all have experience of upgrading Windows
sucks, &lt;a href=&#34;http://osxdaily.com/2014/10/17/os-x-yosemite-installation-stuck/&#34;&gt;same as OS X&lt;/a&gt;.
All the issues you have in old system will be remained, and sometimes
new issues will be introduced in the process of upgrading. The system
will be slower compare to clean install one.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>SIR Model of Epidemics</title>
      <link>https://guangchuangyu.github.io/2014/10/sir-model-of-epidemics/</link>
      <pubDate>Mon, 13 Oct 2014 05:57:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/10/sir-model-of-epidemics/</guid>
      <description>&lt;p&gt;The SIR model divides the population to three compartments:
&lt;strong&gt;S&lt;/strong&gt;usceptible, &lt;strong&gt;I&lt;/strong&gt;nfected and &lt;strong&gt;R&lt;/strong&gt;ecovered. If the disease dynamic
fits the SIR model, then the flow of individuals is one direction from
the susceptible group to infected group and then to the recovered group.
All individuals are assumed to be identical in terms of their
susceptibility to infection, infectiousness if infected and mixing
behaviour associated with disease transmission.&lt;/p&gt;
&lt;p&gt;We defined: $S_t$ = the number of susceptible individuals at time t&lt;/p&gt;
&lt;p&gt;$ I_t $ = the number of infected individuals at time t&lt;/p&gt;
&lt;p&gt;$R_t$ = the number of recovered individuals at time t&lt;/p&gt;
&lt;p&gt;Suppose on average every infected individual will contact $\gamma$
person, and $\kappa$ percent of these $\gamma$ person will be
infected. Then on average there are $\beta = \gamma \times \kappa$
person will be infected an infected individual.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>multiple annotation in ChIPseeker</title>
      <link>https://guangchuangyu.github.io/2014/10/multiple-annotation-in-chipseeker/</link>
      <pubDate>Wed, 01 Oct 2014 13:00:33 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/10/multiple-annotation-in-chipseeker/</guid>
      <description>&lt;h3 id=&#34;nearest-gene-annotation&#34;&gt;Nearest gene annotation&lt;/h3&gt;
&lt;p&gt;Almost all annotation software calculate the distance of a peak to the
nearest TSS and assign the peak to that gene. This can be misleading, as
binding sites might be located between two start sites of different
genes or hit different genes which have the same TSS location in the
genome.&lt;/p&gt;
&lt;p&gt;The function &lt;em&gt;annotatePeak&lt;/em&gt; provides option to assign genes with a max
distance cutoff and all genes within this distance were reported for
each peak.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>install 454 GS Data Analysis Software on ubuntu</title>
      <link>https://guangchuangyu.github.io/2014/09/install-454-gs-data-analysis-software-on-ubuntu/</link>
      <pubDate>Thu, 04 Sep 2014 15:38:44 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/09/install-454-gs-data-analysis-software-on-ubuntu/</guid>
      <description>Usually Roche&amp;rsquo;s installer is a catastrophe, they only provides rpm packages of the software for 454 GS FLX (version 2.9). Although the package contains setup.sh, the script is useless since it is actually a binary payload.
I run the setup.sh, and it throw error of not finding /sbin/lspci. In debian derived distribution, lspci command is located in /bin folder. This issue is easy to solve by adding a soft link to /sbin/lspci.</description>
    </item>
    
    <item>
      <title>简简单单讲insertion size</title>
      <link>https://guangchuangyu.github.io/2014/08/insertion-size/</link>
      <pubDate>Wed, 27 Aug 2014 11:44:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/08/insertion-size/</guid>
      <description>&lt;p&gt;在进行测序的时候，需要将DNA打断，构建library，这些fragment需要接上adaptor，好进行扩增，illumina的测序，可以有single
end和paired end两种，分别从一端和两端进行测序。&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;fragment                  ========================================
fragment + adaptors    ~~~========================================~~~
SE read                   ---------&amp;gt;
PE reads                R1---------&amp;gt;                    &amp;lt;---------R2
unknown gap                         ....................
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>The spread of new mutations</title>
      <link>https://guangchuangyu.github.io/2014/08/the-spread-of-new-mutations/</link>
      <pubDate>Wed, 13 Aug 2014 11:24:35 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/08/the-spread-of-new-mutations/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;Genetic drift is the term used in population genetics to refer to the statistical drift over time of gene frequencies in a population due to random sampling effects in the formation of successive generations.
In a narrower sense, genetic drift refers to the expected population dynamics of neutral alleles (those defined as having no positive or negative impact on reproductive fitness), which are predicted to eventually become fixed at zero or 100% frequency in the absence of other mechanisms affecting allele distributions.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;The most important keyword in the definition of &lt;em&gt;genetic drift&lt;/em&gt; is &lt;strong&gt;random sampling effects&lt;/strong&gt;. The figure belowed illustrates this idea. The surviving individuals do not necessarily have selection advantage. They are randomly selected.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>why clusterProfiler fails</title>
      <link>https://guangchuangyu.github.io/2014/08/why-clusterprofiler-fails/</link>
      <pubDate>Thu, 07 Aug 2014 05:46:35 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/08/why-clusterprofiler-fails/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://github.com/kaji331&#34;&gt;@kaji331&lt;/a&gt;
compared &lt;code&gt;cluserProfiler&lt;/code&gt; with &lt;code&gt;GeneAnswers&lt;/code&gt; and found that clusterProfiler
gives larger p values.&lt;/p&gt;
&lt;p&gt;It eventually came out that he passed the input
gene as numeric vector, which was supposed to be character and he used an &lt;strong&gt;old&lt;/strong&gt; version of &lt;code&gt;clusterProfiler&lt;/code&gt; which didn&amp;rsquo;t use &lt;code&gt;as.character&lt;/code&gt; to coerce the input&lt;/p&gt;
&lt;p&gt;But his comment forces me to test it.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>enrichment map</title>
      <link>https://guangchuangyu.github.io/2014/08/enrichment-map/</link>
      <pubDate>Sun, 03 Aug 2014 12:48:15 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/08/enrichment-map/</guid>
      <description>&lt;p&gt;In &lt;a href=&#34;http://www.plob.org/&#34;&gt;PLOB&lt;/a&gt;&amp;rsquo;s QQ group, someone asked how to change
the color of enrichment map in &lt;a href=&#34;http://cytoscape.org/&#34;&gt;Cytoscape&lt;/a&gt;. I am
very curious how enrichment map can helps to interpret enrichment
results. It took me 2 hours to implement it using R and I am surprised
that the enrichment map is better than anticipated.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>R binary is untrustworthy</title>
      <link>https://guangchuangyu.github.io/2014/07/r-binary-is-untrustworthy/</link>
      <pubDate>Thu, 24 Jul 2014 04:22:35 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/07/r-binary-is-untrustworthy/</guid>
      <description>去年ubuntu下apt-get了R-3.0.2, 用了没多久就发现了system命令有问题，通常情况下调用系统命令是正常的，但是我调用bowtie的时候，就会报错：
Warning: Could not open read file &amp;quot;/tmp/8156.inpipe1&amp;quot; for reading; skipping...Error: Encountered internal Bowtie 2 exception (#1)Command: /usr/bin/bowtie2-align --wrapper basic-0 -p 12 -x /ssd/genomes/hg19 -S tmp.sam -1 /tmp/8156.inpipe1 -2 /tmp/8156.inpipe2 这很明显是因为fasta.gz文件，bowtie需要调用zcat来读的，在R里调用bowtie就找不到好基友zcat的输出管道。当时没在意，R不干，那就找shell。 去年用NMF包的时候，报出了人类不友好的错误，联系了包作者Gaujoux，在作者的帮助下，找到了是doParallel包的问题：
&amp;gt; library(doParallel)&amp;gt; Loading required package: foreachforeach: simple, scalable parallel programming from Revolution AnalyticsUse Revolution R for scalability, fault tolerance and more.http://www.revolutionanalytics.comLoading required package: iteratorsLoading required package: parallel&amp;gt;registerDoParallel(11)&amp;gt; &amp;gt;foreach(i = 1:10) %dopar% { getwd() }&amp;gt;*** caught segfault ***address 0x7fbeb6d399d0, cause &#39;memory not mapped&#39; 其实parallel包中用mclapply也是同样报错。于是又把维护deb包的Dirk拉进来，Dirk是Rcpp的作者，高人就是不一样，看了错误，立刻就指出是BLAS库的问题。</description>
    </item>
    
    <item>
      <title>主成分分析</title>
      <link>https://guangchuangyu.github.io/2014/07/principle_component_analysis/</link>
      <pubDate>Tue, 15 Jul 2014 11:37:55 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/07/principle_component_analysis/</guid>
      <description>&lt;p&gt;使用《Bioinformatics and Molecular Evolution》Table 2.2 (page 24)中的数据:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;gt; aa
  VOL  BULK POLARITY    PI HYD1  HYD2 SURFACE_AREA FRACT_AREA
A  67 11.50     0.00  6.00  1.8   1.6          113       0.74
R 148 14.28    52.00 10.76 -4.5 -12.3          241       0.64
N  96 12.28     3.38  5.41 -3.5  -4.8          158       0.63
D  91 11.68    49.70  2.77 -3.5  -9.2          151       0.62
C  86 13.46     1.48  5.05  2.5   2.0          140       0.91
Q 114 14.45     3.53  5.65 -3.5  -4.1          189       0.62
E 109 13.57    49.90  3.22 -3.5  -8.2          183       0.62
G  48  3.40     0.00  5.97 -0.4   1.0           85       0.72
H 118 13.69    51.60  7.59 -3.2  -3.0          194       0.78
I 124 21.40     0.13  6.02  4.5   3.1          182       0.88
L 124 21.40     0.13  5.98  3.8   2.8          180       0.85
K 135 15.71    49.50  9.74 -3.9  -8.8          211       0.52
M 124 16.25     1.43  5.74  1.9   3.4          204       0.85
F 135 19.80     0.35  5.48  2.8   3.7          218       0.88
P  90 17.43     1.58  6.30 -1.6  -0.2          143       0.64
S  73  9.47     1.67  5.68 -0.8   0.6          122       0.66
T  93 15.77     1.66  5.66 -0.7   1.2          146       0.70
W 163 21.67     2.10  5.89 -0.9   1.9          259       0.85
Y 141 18.03     1.61  5.66 -1.3  -0.7          229       0.76
V 105 21.57     0.13  5.96  4.2   2.6          160       0.85
&amp;gt; aa.pc=prcomp(aa, center=TRUE, scale.=TRUE)
&amp;gt; aa.pc
Standard deviations:
[1] 1.88954924 1.67729608 0.88574923 0.65278312 0.53130822 0.27233782 0.21394709
[8] 0.05808934

Rotation:
                     PC1         PC2           PC3         PC4        PC5
VOL           0.05790316 -0.58494270  0.1057571970 -0.09311996  0.1684497
BULK         -0.22089815 -0.48085679  0.1685873871 -0.15647005 -0.6842181
POLARITY      0.44390146 -0.10372198  0.1432388489  0.73088587 -0.1747201
PI            0.18580066 -0.25244261 -0.9417631776  0.02722752 -0.0522075
HYD1         -0.49279466 -0.03284274 -0.1281013177  0.35033569 -0.3534423
HYD2         -0.50821923  0.03312719 -0.1292531953 -0.12776013  0.1837842
SURFACE_AREA  0.10045084 -0.56587879  0.1408585179 -0.10640314  0.3652725
FRACT_AREA   -0.45283231 -0.17244828  0.0009997326  0.53059489  0.4220135
                     PC6         PC7          PC8
VOL          -0.11705506  0.21351836 -0.739571539
BULK          0.25124136 -0.35181704  0.109655303
POLARITY      0.39252691  0.22974777  0.009653888
PI            0.04562347 -0.09136074  0.030622127
HYD1         -0.50083501  0.48686655  0.064292387
HYD2          0.70974650  0.41191312 -0.019940539
SURFACE_AREA -0.11107422  0.24097250  0.659316956
FRACT_AREA   -0.01018472 -0.55201871 -0.027363410
&amp;gt; summary(aa.pc)
Importance of components:
                          PC1    PC2     PC3     PC4     PC5     PC6     PC7
Standard deviation     1.8895 1.6773 0.88575 0.65278 0.53131 0.27234 0.21395
Proportion of Variance 0.4463 0.3517 0.09807 0.05327 0.03529 0.00927 0.00572
Cumulative Proportion  0.4463 0.7980 0.89603 0.94930 0.98459 0.99386 0.99958
                           PC8
Standard deviation     0.05809
Proportion of Variance 0.00042
Cumulative Proportion  1.00000
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;PC1和PC2能够解释79.8%的variation。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>use linux desktop again</title>
      <link>https://guangchuangyu.github.io/2014/06/use-linux-desktop-again/</link>
      <pubDate>Sun, 01 Jun 2014 07:57:46 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/06/use-linux-desktop-again/</guid>
      <description>&lt;p&gt;上个月写了《&lt;a href=&#34;http://guangchuangyu.github.io/2014/05/use-ggplot2/&#34;&gt;使用ggplot画图&lt;/a&gt;》一文，图片太多，一下子把博客的12G流量给用光了，月中博客就被停了，小伙伴们太给力了，blog不能访问，真是件不爽的事情。&lt;/p&gt;
&lt;p&gt;言归正传，从2002年使用redhat 7.1开始，就没中止过使用linux，为什么要说again呢，因为在过去几年的工作时间里，使用的是&lt;a href=&#34;http://guangchuangyu.github.io/2011/06/screen-shot/&#34;&gt;OS X&lt;/a&gt;和win7做为桌面的，linux只在服务器端使用。自从用了OS X之后，就不想再用linux当桌面了，OS X绝对是节省生命的系统，本身是unix-like系统，对各种桌面软件支持又好，特别是中华大地，linux还是小众，用来当桌面实在是各种坑。&lt;/p&gt;
&lt;p&gt;不过现在又回到学生时代了，所以还得继续学生屌丝的折腾，本科时从redhat,debian到gentoo，硕士时实验室的机器用ubuntu，而笔记本用NetBSD。这么多年的使用，该有的坑都填了，但是时代在发展，新坑还是不断有的，使用&lt;a href=&#34;http://guangchuangyu.github.io/2014/05/%E6%9B%B4%E6%94%B9%E7%99%BE%E5%BA%A6%E4%BA%91%E5%90%8C%E6%AD%A5%E7%9B%98%E8%B7%AF%E5%BE%84/&#34;&gt;百度云&lt;/a&gt;来同步化文献库，就是最近的新坑，装上linux之后，发现度娘没有客户端，首先想到的当然是wine，wine出来的偶尔能行，时常崩溃，跟它死磕我也会崩溃，github上寻找开源实现，各种功能缺失和限制，那就只能虚拟机了，把home目录做为共享盘，挂到虚拟机中，但是度娘一直都是占100%
CPU，然后数据无法同步，只有两个原因，不是硬盘就是网络，感觉好像我一个分区800G太大了，但在虚拟中对硬盘读写正常，网络因为使用NAT，虚拟成内网，有可能是这个原因，于是换成bridge，把虚拟机当成现实网络中的另一台主机，但度娘依然只占CPU，不干活。那只能还是硬盘问题，最后问题解决了，通过在linux中提供samba服务，然后在虚拟机中通过网上邻居把共享目录映射成网络驱动器，这时候度娘终于肯干活了。都不知道是virtualbox的驱动有问题，还是度娘太挑，这太TM坑了。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Use ggplot2</title>
      <link>https://guangchuangyu.github.io/2014/05/use-ggplot2/</link>
      <pubDate>Sun, 11 May 2014 06:17:56 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/05/use-ggplot2/</guid>
      <description>&lt;h3 id=&#34;why-use-ggplot2&#34;&gt;Why use ggplot2&lt;/h3&gt;
&lt;p&gt;ggplot2是我见过最human friendly的画图软件，这得益于Leland Wilkinson在他的著作《&lt;a href=&#34;http://book.douban.com/subject/10123863/&#34;&gt;The Grammar of Graphics&lt;/a&gt;》中提出了一套图形语法，把图形元素抽象成可以自由组合的成分，Hadley
Wickham把这套想法在R中实现。&lt;/p&gt;
&lt;p&gt;为什么要学习ggplot2，可以参考&lt;a href=&#34;http://book.douban.com/subject/24527091/&#34;&gt;ggplot2: 数据分析与图形艺术&lt;/a&gt;的&lt;a href=&#34;https://github.com/cosname/ggplot2-translation/blob/master/preface.md&#34;&gt;序言&lt;/a&gt;（btw: 在序言的最后，我被致谢了）。&lt;/p&gt;
&lt;p&gt;Hadley Wickham也给出&lt;a href=&#34;https://github.com/hadley/ggplot2/wiki/Why-use-ggplot2&#34;&gt;一堆理由&lt;/a&gt;让我们说服自己，我想再补充一点，Hadley Wickham是学医出身的，做为学生物出身的人有什么理由不支持呢:)&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>更改百度云同步盘路径</title>
      <link>https://guangchuangyu.github.io/2014/05/%E6%9B%B4%E6%94%B9%E7%99%BE%E5%BA%A6%E4%BA%91%E5%90%8C%E6%AD%A5%E7%9B%98%E8%B7%AF%E5%BE%84/</link>
      <pubDate>Mon, 05 May 2014 10:45:25 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/05/%E6%9B%B4%E6%94%B9%E7%99%BE%E5%BA%A6%E4%BA%91%E5%90%8C%E6%AD%A5%E7%9B%98%E8%B7%AF%E5%BE%84/</guid>
      <description>&lt;p&gt;从2007年写了&lt;a href=&#34;http://cjbmb.bjmu.edu.cn/CN/abstract/abstract17570.shtml&#34;&gt;第一篇文章&lt;/a&gt;之后，我发现管理文献真不是人干的，一直以来使用Zotero来管理文献，自从有了dropbox之后，就想把文献库放在dropbox上，一来有个云备份，不怕硬盘坏，二来嘛，实验室电脑和个人电脑可以实时同步化，无奈dropbox空间太小，而我的zotero早已超过10G，因为电子书也放在里面，只能做罢。&lt;/p&gt;
&lt;p&gt;度娘出手还是很大方的，我现在的网盘已经有3T，包括之前在推广阶段用1元买的1T。&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2014/05/Screenshot-2014-05-05-21.31.57.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>visualization methods in ChIPseeker</title>
      <link>https://guangchuangyu.github.io/2014/04/visualization-methods-in-chipseeker/</link>
      <pubDate>Wed, 30 Apr 2014 06:33:41 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/04/visualization-methods-in-chipseeker/</guid>
      <description>&lt;p&gt;After two weeks developed, I have added/updated some plot functions in
&lt;a href=&#34;http://bioconductor.org/packages/release/bioc/html/ChIPseeker.html&#34;&gt;ChIPseeker&lt;/a&gt;
(version &amp;gt;=1.0.1).&lt;/p&gt;
&lt;h3 id=&#34;chip-peaks-over-chromosomes&#34;&gt;ChIP peaks over Chromosomes&lt;/h3&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;&amp;gt; files=getSampleFiles()
&amp;gt; peak=readPeakFile(files[[4]])
&amp;gt; peak
GRanges object with 1331 ranges and 2 metadata columns:
         seqnames                 ranges strand   |             V4        V5
                               |        
     [1]     chr1     [ 815092,  817883]      *   |    MACS_peak_1    295.76
     [2]     chr1     [1243287, 1244338]      *   |    MACS_peak_2     63.19
     [3]     chr1     [2979976, 2981228]      *   |    MACS_peak_3    100.16
     [4]     chr1     [3566181, 3567876]      *   |    MACS_peak_4    558.89
     [5]     chr1     [3816545, 3818111]      *   |    MACS_peak_5     57.57
     ...      ...                    ...    ... ...            ...       ...
  [1327]     chrX [135244782, 135245821]      *   | MACS_peak_1327     55.54
  [1328]     chrX [139171963, 139173506]      *   | MACS_peak_1328    270.19
  [1329]     chrX [139583953, 139586126]      *   | MACS_peak_1329    918.73
  [1330]     chrX [139592001, 139593238]      *   | MACS_peak_1330    210.88
  [1331]     chrY [ 13845133,  13845777]      *   | MACS_peak_1331     58.39
  ---
  seqlengths:
    chr1 chr10 chr11 chr12 chr13 chr14 ...  chr6  chr7  chr8  chr9  chrX  chrY
      NA    NA    NA    NA    NA    NA ...    NA    NA    NA    NA    NA    NA
&amp;gt; covplot(peak, weightCol=&amp;quot;V5&amp;quot;)
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>ChIPseeker for ChIP peak annotation</title>
      <link>https://guangchuangyu.github.io/2014/04/chipseeker-for-chip-peak-annotation/</link>
      <pubDate>Sun, 13 Apr 2014 13:02:15 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/04/chipseeker-for-chip-peak-annotation/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://www.bioconductor.org/packages/2.14/bioc/html/ChIPpeakAnno.html&#34;&gt;ChIPpeakAnno&lt;/a&gt;
WAS the only R package for ChIP peak annotation. I used it for
annotating peak in my recent study.&lt;/p&gt;
&lt;p&gt;I found it does not consider the strand information of genes. I
&lt;a href=&#34;http://guangchuangyu.github.io/2014/01/bug-of-r-package-chippeakanno/&#34;&gt;reported the bug&lt;/a&gt; to the
authors, but they are reluctant to change.&lt;/p&gt;
&lt;p&gt;So I decided to develop my own package,
&lt;a href=&#34;http://www.bioconductor.org/packages/2.14/bioc/html/ChIPseeker.html&#34;&gt;ChIPseeker&lt;/a&gt;,
and it&amp;rsquo;s now available in Bioconductor.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>boxplot</title>
      <link>https://guangchuangyu.github.io/2014/03/boxplot/</link>
      <pubDate>Tue, 04 Mar 2014 12:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/03/boxplot/</guid>
      <description>&lt;p&gt;生物坑很多人画图只会直方图，统计只会T检验，在暨大见过太多的学生连T检验都不会，分不清SEM和SD的差别，也不清楚T检验那几个简单参数的含义。我写统计笔记也是因为不想重复性地跟学生讲解T检验。&lt;/p&gt;
&lt;p&gt;Barplot和T test一样普遍而流行，barplot适合于表示计数数据和比例，显示比例也可以用pie
plot，但直方图比饼图要好，因为人类的眼睛适合于比较高度，而不是弧度。&lt;/p&gt;
&lt;p&gt;多半时候生物学数据并非简单的计数数据，对于测量数据，在展示数据分布时，很多人会使用他们熟悉的barplot，用高度来表示mean，然后再加上errorbar，这样展示数据，信息量是非常低的，使用boxplot能够提供更多的数据分布信息，能更好地展现数据，但可能很多人只会在excel里画barplot，Nature
Methods 2013年的文章中有100个barplot图，而只有20个boxplot图，从这里就可以看出来，用boxplot的人远远没有barplot多，于是NPG怒了，写了两篇专栏文章&lt;a href=&#34;http://www.nature.com/nmeth/journal/v11/n2/full/nmeth.2807.html&#34;&gt;Points of View: Bar charts and box plots&lt;/a&gt;和&lt;a href=&#34;http://www.nature.com/nmeth/journal/v11/n2/full/nmeth.2813.html&#34;&gt;Points of Significance: Visualizing samples with box plots&lt;/a&gt;并且发表了一篇&lt;a href=&#34;http://www.nature.com/nmeth/journal/v11/n2/full/nmeth.2811.html&#34;&gt;BoxPlotR: a web tool for generation of box plots&lt;/a&gt;方便大家画boxplot，如此简单的web tool能够发Nature Methods，实在是让人羡慕妒忌恨啊。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>old habits die hard</title>
      <link>https://guangchuangyu.github.io/2014/01/old-habits-die-hard/</link>
      <pubDate>Wed, 22 Jan 2014 13:27:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/01/old-habits-die-hard/</guid>
      <description>从2011年1月我就在实验室的QQ群里发群邮件说IPI关门，时至今日，已经关门3年了，主页上一直停留在关门大吉的那一刻。
我不断在邮件里, lab meeting上强调要换成uniprot来搜库，然而时至今日，依然还是有很多的人在使用IPI，想想真可怕，实验室真是100年不更新一下数据啊。 另外一个我非常讨厌的就是GI号，它压根就不是正儿八经的ID号，但他们从来就不愿意尝试改变。
比如上面这个蛋白质序列的FASTA文件，注释行有很多信息，比如：
&amp;gt;gi|16128001|ref|NP_414548.1| putative transporter [Escherichia coli str. K-12 substr. MG1655]显然搜库时可以使用NP_414548.1做为ID，这个问题我说过N多遍，但他们一定会用他们惯用的gi|16128001来做ID。
问题是很明显的：
 GI number (sometimes written in lower case, &amp;ldquo;gi&amp;rdquo;) is simply a series of digits that are assigned consecutively to each sequence record processed by NCBI. The GI number bears no resemblance to the Accession number of the sequence record. The GI number has been used for many years by NCBI to track sequence histories in GenBank and the other sequence databases it maintains.</description>
    </item>
    
    <item>
      <title>Bug of R package ChIPpeakAnno</title>
      <link>https://guangchuangyu.github.io/2014/01/bug-of-r-package-chippeakanno/</link>
      <pubDate>Tue, 14 Jan 2014 17:09:07 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2014/01/bug-of-r-package-chippeakanno/</guid>
      <description>&lt;p&gt;I used R package &lt;strong&gt;ChIPpeakAnno&lt;/strong&gt; for annotating peaks, and found that
it handle the DNA strand in the wrong way. Maybe the developers were
from the computer science but not biology background.&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;&amp;gt; require(ChIPpeakAnno)
&amp;gt; packageVersion(&amp;quot;ChIPpeakAnno&amp;quot;)
[1] &#39;2.10.0&#39;
&amp;gt; peak &amp;lt;- RangedData(space=&amp;quot;chr1&amp;quot;, IRanges(24736757, 24737528))
&amp;gt; data(TSS.human.GRCh37)
&amp;gt; ap &amp;lt;- annotatePeakInBatch(peak, Annotation=TSS.human.GRCh37)
&amp;gt; ap
RangedData with 1 row and 9 value columns across 1 space
                     space               ranges |        peak      strand
                               |  
1 ENSG00000001461        1 [24736757, 24737528] |           1           +
                          feature start_position end_position insideFeature
                                   
1 ENSG00000001461 ENSG00000001461       24742284     24799466      upstream
                  distancetoFeature shortestDistance fromOverlappingOrNearest
                                                
1 ENSG00000001461             -5527             4756             NearestStart
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>local blast</title>
      <link>https://guangchuangyu.github.io/2013/11/local-blast/</link>
      <pubDate>Thu, 21 Nov 2013 10:40:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2013/11/local-blast/</guid>
      <description>I was asked to set up a local blast for the lab. Blast can be installed directly using apt in debian and it turns out to be easy.
root@jz:/ssd/genomes# apt-get install ncbi-blast+Reading package lists... DoneBuilding dependency treeReading state information... DoneThe following NEW packages will be installed:ncbi-blast+0 upgraded, 1 newly installed, 0 to remove and 26 not upgraded.Need to get 11.2 MB of archives.After this operation, 32.</description>
    </item>
    
    <item>
      <title>Run remote R in Emacs with ESS</title>
      <link>https://guangchuangyu.github.io/2013/11/run-remote-r-in-emacs-with-ess/</link>
      <pubDate>Thu, 14 Nov 2013 17:44:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2013/11/run-remote-r-in-emacs-with-ess/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://guangchuangyu.github.io/tags/emacs/&#34;&gt;Emacs&lt;/a&gt; is a great front-end for most of the command line tools. Although R-Studio is pretty good, I think Emacs/&lt;a href=&#34;http://guangchuangyu.github.io/tags/ess/&#34;&gt;ESS&lt;/a&gt; is better. I’ve always used Emacs/ESS to run R, since 2007 on Ubuntu, &lt;a href=&#34;http://guangchuangyu.github.io/cn/2011/12/word-freq/&#34;&gt;Windows&lt;/a&gt;, and my &lt;a href=&#34;https://guangchuangyu.github.io/cn/2011/06/screen-shot/&#34;&gt;MacBook Pro&lt;/a&gt;. It gives me the same experiences across all platforms. I love the way Emacs formatting source codes, and literate programming with &lt;a href=&#34;http://roxygen.org/&#34;&gt;Roxygen&lt;/a&gt; supported. Unfortunately, ESS does not suport displaying plots in Emacs buffer, &lt;a href=&#34;https://guangchuangyu.github.io/cn/2005/05/%E5%9C%A8emacs%E9%87%8C%E4%BD%BF%E7%94%A8maxima/&#34;&gt;which has been supported by imaxima&lt;/a&gt;.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Install Emacs on Mac</title>
      <link>https://guangchuangyu.github.io/2013/09/install-emacs-on-mac/</link>
      <pubDate>Tue, 10 Sep 2013 18:04:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2013/09/install-emacs-on-mac/</guid>
      <description>&lt;h2 id=&#34;package-manager&#34;&gt;package manager&lt;/h2&gt;
&lt;p&gt;之前一直用&lt;a href=&#34;http://guangchuangyu.github.io/categories/bsd/&#34;&gt;NetBSD&lt;/a&gt;的&lt;a href=&#34;http://guangchuangyu.github.io/2007/05/%E6%88%91%E5%88%B6%E4%BD%9C%E7%9A%84pkgsrc/&#34;&gt;pkgsrc&lt;/a&gt;做为各种Unix-like系统的包管理系统，pkgsrc在自己内部解决依赖关系，这点对于生产环境来说，是很好的一个优点，我通常会在服务器里装一个pkgsrc，在用户目录下，维护一套UNIX软件。但是用在自己的机器上，内部解决软件依赖，就是个缺点，浪费编译时间和硬盘空间。&lt;/p&gt;
&lt;p&gt;Mac上可用的包管理系统很多，Fink移植于&lt;a href=&#34;http://guangchuangyu.github.io/categories/linux/&#34;&gt;Debian&lt;/a&gt;的apt，&lt;a href=&#34;http://guangchuangyu.github.io/categories/linux/&#34;&gt;Gentoo&lt;/a&gt;的portage也支持OS X。OS X是基于BSD的系统，BSD有自己的一套包管理系统，如FreeBSD的ports和&lt;a href=&#34;http://guangchuangyu.github.io/categories/bsd/&#34;&gt;NetBSD&lt;/a&gt;的&lt;a href=&#34;http://guangchuangyu.github.io/2007/05/%E6%88%91%E5%88%B6%E4%BD%9C%E7%9A%84pkgsrc/&#34;&gt;pkgsrc&lt;/a&gt;，MacPorts可以看作是这一系列中的一个，不过它并不是OS X原生的，它只是OpenDarwin的子项目，所以和pkgsrc一个样，也是内部解决依赖，真正为OS
X设计的原生包管理系统非Homebrew莫属，它会尽量依赖系统里已有的软件。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Permanent Head Damage to be</title>
      <link>https://guangchuangyu.github.io/2013/07/permanent-head-damage-to-be/</link>
      <pubDate>Tue, 30 Jul 2013 16:18:26 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2013/07/permanent-head-damage-to-be/</guid>
      <description>&lt;p&gt;看似寻常最奇崛，成如容易却艰辛。在暨大工作了几年，发几篇小文章，觉得要找个地方读PhD，是件手到擒来的事，结果却花了整整一年的时间，事实证明像我这样的科研屌丝男，举步唯艰啊。
去年7月份就开始在计划这个事情，我几乎想都没想就联系了计算生物所的JD
Han，紧接着就是面试，第一次尝试用英文去讲slides，从早上10点讲到中午12点。感觉还好吧，因为有听到Han说impressive，而她的学生又说经常看我blog。看上去还是蛮顺利的，然而最终reject了我，而且没有给我任何原因。&lt;/p&gt;
&lt;p&gt;我去上海是非常低姿态的，说要面试，我就飞过去，当时想要是面试OK了，可能会让我留下来先了解一下正在进行的project，所以没有听老婆的话买返程票，结果从上海回广州，就变成了人在囧途，买不到火车票，就去南昌转车，结果遇到两趟车都是慢车，无空调，还无座。这个事情教会了我，不能太低姿态。&lt;/p&gt;
&lt;p&gt;我一直在想为什么会去上海，为什么会联系Han，或许是心理学上所谓的契可尼效应，俗称偷不如偷不着，当年考上生没中，心中依然有执念？我自认为早已释然，but
maybe..，至于Han，我在研一的时候，去北大听过她的讲座，被系统生物学这个概念忽悠了，可能因此内心抱有幻想。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>使用ImageMagick压缩TIFF</title>
      <link>https://guangchuangyu.github.io/2013/06/compress-tiff/</link>
      <pubDate>Fri, 07 Jun 2013 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2013/06/compress-tiff/</guid>
      <description>TIFF (Tagged Image File Format)拥有更宽的线性动态范围，所以在专业的图片处理上，一直是一个通用的文件格式。
最近一篇发表在Metallomics的文章，我本来做的图片都是PDF格式，矢量图最好了，文件特别小，还可以任意放大。不过杂志社要求600DPI的TIFF或EPS。
我第一反应是拒绝使用TIFF，600DPI的TIFF文件肯定非常大，EPS也是矢量图，我用R重新把图画一遍，存为EPS就OK了。画图的过程，我发现对EPS的支持不太好，老报些某字体不存在的错误。这当然不是什么大不了的事，自己指定字体就好了。问题在于有张图是拼的，我只能借助于软件转换，我用Inkscape处理，导出EPS，出来的图我发现有些细节并不太好。
无奈之下还是用TIFF吧，Fig1和3都是R画的，直接指定分辨率和压缩算法，存为TIFF文件。Fig1是3000x3000pixel 600dpi的图，只有320k，Fig3是4200x4200pixel的图，也是600dpi，只有558k，用R产生TIFF还是非常靠谱的。
关键是Fig2，这一张拼的图，存成PDF矢量图，需要用ImageMagick转换成600DPI的TIFF图片，ImageMagick需要安装Xcode才能在Mac下编译成功。
Yus-Mac-Pro:others ygc$ convert -density 600 fig2.pdf fig2.tifYus-Mac-Pro:others ygc$ identify -verbose fig2.tifImage: fig2.tifFormat: TIFF (Tagged Image File Format)Class: DirectClassGeometry: 6000x4500+0+0Resolution: 600x600Print size: 10x7.5Units: UndefinedType: PaletteMatteBase type: TrueColorEndianess: MSB...Yus-Mac-Pro:others ygc$ convert -density 600 -compress lzw fig2.pdf fig2_compress.tifYus-Mac-Pro:others ygc$ ls -l fig2*.tif-rw-r--r-- 1 ygc admin 216036263 May 23 17:53 fig2.</description>
    </item>
    
    <item>
      <title>TALEN基因编辑</title>
      <link>https://guangchuangyu.github.io/2013/01/talen%E5%9F%BA%E5%9B%A0%E7%BC%96%E8%BE%91/</link>
      <pubDate>Thu, 10 Jan 2013 08:40:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2013/01/talen%E5%9F%BA%E5%9B%A0%E7%BC%96%E8%BE%91/</guid>
      <description>分子生物学的基础和兴起离不开各种酶的发现和抗体的制备。没有抗体，蛋白质就玩不转，没有限制性内切酶和连接酶，就没有基因工程，如果没有耐高温酶的发现，连PCR都是件痛苦的事情，写到这里，我突然觉得做细菌也是蛮好的，因为比较有可能发现一些功能比较奇特的蛋白，而这些蛋白，一经改造，可能就是技术上的革新。
TALE(transcription activator-like effector)也不例外，最初在植物致病菌黄单胞菌（Xanthomonas）中被发现，在致病过程中，能够特异性地结合和调控植物基因。
TALE的结构中间（红色部分）是重复序列，介导DNA识别，每一个重复片段为33-35个氨基酸，其中12和13位置两个氨基酸决定碱基偏好性，这两个相邻的氨基酸被称之为重复可变双残基（repeat variable di-residue, RVD），RVD所编码的靶标碱基由上图b所示，基本上你看一段TALE的重复序列，就可以预测到它将结合到什么样的DNA序列上，或者你看一段DNA序列，可以很容易地设计结合它的TALE重复序列。
N端通常是288个残基，其中Δ152做为截断点，去掉前面用于进入植物细胞的功能，而保留TALE蛋白的其它功能。C端通常是278个残基。
中间重复片段的特性使得TALE很容易被改造，应用于各种定点靶向的场景。 Activator 2011年发表在NBT上的文章《A TALE nuclease architecture for efficient genome editing》将TALE改造成促进特定基因表达。将天然TALE进行PCR扩增，去掉前面152个残基，重复序列改造为结合NTF3的启动子邻近区域(proximal promoter)，C端连上VP16（转录激活结构域），结果诱导超过20倍的表达。NTF3基因编码一个分泌性的生长因子，对神经退行性疾病有一个的治疗功效。作者把C端截断，保留95个残基再接上VP16，同样也是mRNA超过20倍的表达。 Nuclease 位点特异性的核酸酶是基因组工程的有力工具，产生断裂的双链DNA（double strand breaks, DSBs），可以进行同源重组、靶向插入、删除。锌指蛋白（zinc finger protein）连接FokI的水解结构域，构成了锌指核酶(zinc finger nuclease, ZFN)被用来进行基因组编辑，但是ZFN的特异性和效率较差，可重复性不好。
TALE的单碱基识别能力，显然在特异性上是无可比拟的，有了TALE，TALEN（TALE-nuclease，TALE接上核酸酶）技术应运而生，特异性好，效率高，而且可以应用于各种物种。TALEN通常以同二聚体（homodimer）或异二聚体（hterodimer）对DNA从两端进行切割，两端切割点的距离（spacer length）可以是10-30bp之间，取决于linker的长度，即连接重复结构域和切割结构域的长度，长的linker，需要长的spacer，反之亦然。
两端切割后，产生DSB，就会引起系统对其进行修复，Miller等使用TALEN对NTF3基因进行切割，产生DSB，随后进行非同源末端连接（non-homologous end joining, NHEJ）修复，NHEJ在没有同源序列做为模版的情况下进行修复，这是一个不精确的修复途径，结果产生了3-30bp的删除。
NHEJ是容易出错也不好控制的，可喜的是还存在一条精确可控的途径，同源依赖修复（homology dependent repair, HDR），在有供体ssDNA存在的情况下，通过HDR途径，可以对基因进行编辑，插入和缺失处理。
于是牛B的事情就产生了，2012年Nature的文章报道在斑马鱼活体组织里使用TALEN技术，引入了定制的EcoRV位点和修改的loxP序列。
Reference 1. Miller, Jeffrey C., Siyuan Tan, Guijuan Qiao, Kyle A. Barlow, Jianbin Wang, Danny F. Xia, Xiangdong Meng, et al. “A TALE Nuclease Architecture for Efficient Genome Editing.” Nature Biotechnology 29, no.</description>
    </item>
    
    <item>
      <title>2012豆瓣记录</title>
      <link>https://guangchuangyu.github.io/2012/12/2012-douban/</link>
      <pubDate>Mon, 24 Dec 2012 16:20:43 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2012/12/2012-douban/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/2012/12/douban2012-1024x1024.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;又一年过去了，看书的数目总算是追上看碟了。
5本R方面的书，两本是入门书，快速翻阅过，&lt;a href=&#34;http://ygc.name/2011/09/24/scientific-programming/&#34;&gt;Introduction to Scientific
Programming and Simulation Using
R&lt;/a&gt;我觉得和&lt;a href=&#34;http://book.douban.com/subject/1756393/&#34;&gt;Intermediate
Perl&lt;/a&gt;属于同一类，算是进阶阶段的书，有编程基础的话，这种才是最好的入门书。R
Inferno讲了R的各种陷阱，ggplot2是关于画图，比如上面的拆线图，就是用ggplot画的，从一开始用ggplot2就开始翻看这本书，N长时间过去了，也没看完，直到今年要出中文版，我也帮忙较对了一下，才把它看完。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>如何获取文献</title>
      <link>https://guangchuangyu.github.io/2012/09/%E5%A6%82%E4%BD%95%E8%8E%B7%E5%8F%96%E6%96%87%E7%8C%AE/</link>
      <pubDate>Mon, 10 Sep 2012 14:53:35 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2012/09/%E5%A6%82%E4%BD%95%E8%8E%B7%E5%8F%96%E6%96%87%E7%8C%AE/</guid>
      <description>这个题目又标题党了，不过是share一下一些地球人都应该知道的小tips而已。
据说是电信出口出了问题，学校里这两天大家都在叫pubmed上不去，我反正是上得去，就是慢点。大家好像少了pubmed就无法干活似的，不过也是，正所谓：熟读唐诗三百首，不会作诗也会吟。
1.有备无患
pubmed上不去，完全没影响，因为有hubmed,hubmed主页上写着：An alternative interface to the PubMed medical literature database，所以完全可以把它当作是pubmed的镜像。这个站点至少我在暨大上是超级快的。搜完底上还有链接，让你很方便地用同样的关键词在google (scholar)，Scirus, CrossRef，EBIMed等其它数据库里搜。
另外一个备选的站点是gopubmed，这个站点的亮点是整合了ontology。
最近欧洲大名鼎鼎的EBI也开始搞文献服务了，新开的Europe PubMed Central，我比较喜欢它的排序功能，可以按文章的相关性或引用数来排。除了文献之后，还可以biological patents, clinical guidelines, PhD theses and research reports。这个站点现在刚创立，我觉得一两年之后，肯定会有更多的服务提供，前途无量啊。
文献管理 读文献是人干的事，管理文献却是疯子干的事。如果你还活在手工整理文献的黑客帝国里，请赶紧吞下红色药丸。  3.个性化推荐 上网买本书，电商都会推荐给你，某本书可能你也想买。这是个性化推荐的时代，读文献也不例外，Google Scholar的新功能My updates，干的就是这个事，可以根据自己文章的内容，推荐相关的最新文献，想要用到这个功能，你需要建立google scholar profile页面。
4.订阅 RSS改变了人类的阅读，很多的期刊都提供了RSS，如果你是火星人，不知道啥是RSS，那么打开你的QQ邮箱，点一下阅读空间，那玩意实现的就是RSS订阅了。个人比较推荐google reader。
另一个值得一提的是NCBI的个性化服务My NCBI，你可以设定关键词，当pubmed上有新文献和这个关键词匹配的话，NCBI可以定期给你发邮件提醒。
5.求文献
科研大军越来越庞大，笑到最后的是各大出版社，不是读者给它送钱，就是作者给它送钱，当我们点full text时却被告知没付费么有permission，天下文章一大抄，没得抄是多么的不爽。我以前喜欢在FriendFeed上的references wanted里求下载。不过上friendfeed需要一支红杏出墙来。现在好了，国内的丁香园有个一键求助的功能，是个求文献的好去处。
6.下文献
文献下不了，很多时候是不用求的，sci-hub.org这个代理就是个下文献的好地方，比Phosphoproteome profile of human lung cancer cell line A549这篇文章的网址是http://pubs.rsc.org/en/Content/ArticleLanding/2011/MB/C0MB00055H，把URL加上sci-hub.org这个代理，变成http://pubs.rsc.org.sci-hub.org/en/Content/ArticleLanding/2011/MB/C0MB00055H，就可以下到相应的PDF文件。
欢迎补充。 PS:今天收到一颗树~ </description>
    </item>
    
    <item>
      <title>tricky things in R</title>
      <link>https://guangchuangyu.github.io/2012/07/tricky-things-in-r/</link>
      <pubDate>Tue, 10 Jul 2012 07:16:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2012/07/tricky-things-in-r/</guid>
      <description>&lt;pre&gt;&lt;code&gt; ________________________________________________________________
/  ____    _                                                     \
| |  _ \  (_)___    __ ___      _____  ___  ___  _ __ ___   ___  |
| | |_) | | / __|  / _` \ \ /\ / / _ \/ __|/ _ \| &#39;_ ` _ \ / _ \ |
| |  _ &amp;lt;  | \__ \ | (_| |\ V  V /  __/\__ \ (_) | | | | | |  __/ |
| |_| \_\ |_|___/  \__,_| \_/\_/ \___||___/\___/|_| |_| |_|\___| |
\                                                                /
 ----------------------------------------------------------------
        \   ^__^
         \  (oo)\_______
            (__)\       )\/\
                ||----w |
                ||     ||
&lt;/code&gt;&lt;/pre&gt;
&lt;ol&gt;
&lt;li&gt;赋值&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;从一开始学R就知道R的赋值符号和别的语言不一样，用的是&lt;code&gt;&amp;lt;-&lt;/code&gt;，虽然&lt;code&gt;=&lt;/code&gt;也用，很多书会告诉你两者是一样的，完全通用，不过用R的人习惯也推倡用&lt;code&gt;&amp;lt;-&lt;/code&gt;。所以我基本上就抛弃用&lt;code&gt;=&lt;/code&gt;号了，反正在ESS里用shift+-就会自动输入&lt;code&gt;&amp;lt;-&lt;/code&gt;，也是很方便的。直到有一天，我发现&lt;!-- raw HTML omitted --&gt;在switch里，必须用&lt;code&gt;=&lt;/code&gt;号&lt;!-- raw HTML omitted --&gt;，而不能用&lt;code&gt;&amp;lt;-&lt;/code&gt;，才发现坑爹啊，这两符号是不一样的。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>什么是T 检验</title>
      <link>https://guangchuangyu.github.io/2012/05/%E4%BB%80%E4%B9%88%E6%98%AFt-%E6%A3%80%E9%AA%8C/</link>
      <pubDate>Tue, 29 May 2012 06:17:56 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2012/05/%E4%BB%80%E4%B9%88%E6%98%AFt-%E6%A3%80%E9%AA%8C/</guid>
      <description>跟某同学讲了T test之后，整理一下。
很多的检验和我们的直觉是一致的，前阵子在一个群里，有管理学院的人问说想看两个样本是不是来自于同一个分布，我叫他画两个CDF，一看就知道。对方说不要看图，我就让他用Kolmogorov-Smirnov Tests。我自己搜了一下，发现ks.test检验的就是拿两个CDF的距离做为统计量，虽然计算很复杂，但是和intuition那是相当一致啊。
最简单也最常用的，莫过于T检验，用我们的直觉就可以理解了，但是我发现不理解还有用错的人也挺多的。
我们要看一个样本的均值是不是等于0，最naive的办法就是看样本的均值和0差别多大。
这个比较之所以naive，因为没有考虑到数据的分布，从上图的两个populations来看，它们的均值都是0，从绿色的分布中抽到一个均值为3的样本，概率并不小，但是从红色的分布中得到这样一个样本，那就是小概率事件。所以不能单纯比较均值，而是要看均值的分布，从上面的populations上看，和数据的离散程度有关。 我们随机抽取100个sample，得到以下的均值分布：
我们需要对均值的离散程度做penalty，那么就可以考虑这样一个统计量mean(x)/SEM, SEM代表standard error of the mean，那么这个统计量比单纯的均值要科学得多。这个统计量，就是学生氏所定义的t。
如果没有大量的样本，是没办法估计SEM的，但是从上面两个图上看，样本间均值的标准误SEM，和总体数据的标准误是正相关的。而总体的标准误可以用样本的标准误,sd(x),来估计。如果我们考虑最简单的形式呢？定义统计量mean(x)/sd(x)。
那么，请等一下，我们还需要考虑到样本量的影响，如果sample size没有影响，那么我们就不需要采集大样本了。从我们的直觉上看，肯定是样本量越大，对总体参数的估计越准确了。
从图上看，还是和直觉很一致。sample size越大，分布越compact，对总体均值的估计也就越准确。那么就需要使用sample size进行加权，把统计量修改为mean(x)/sd(x) * f(n)，其中n为sample size。
我们可以想像，学生氏当年try了几种形式的f(n)，发现sqrt(n)效果最好。于是他就定义了统计量: t = mean(x)/(sd(x)/sqrt(n))。 sqrt(n)效果好，因为sd(x)/sqrt(n)正好是对样本间均值标准误SEM的估计。
我们又可以想像，学生氏当年收集了很多个样本，计算了多个t值，发现这些t值的分布是有规律的，有点像正态分布，学生氏把它定义为t分布，利用t分布的probability density function，就可以计算p-value啦。
上图就是从标准正态分布里抽取100个样本，所计算的t值分布。
很多人上课学不懂，我觉得是因为一上来告诉你t怎么算，但是没让你理解SEM，SEM是理解t值计算的关键。
算完t之后，一句话，符合t分布，然后就是查表看p值,或者让计算机算，太抽象，这世界本来没有t分布，是学生氏定义了t统计量，并发现符合某分布，把它定义为t分布，有计算机做simulation，重现这个过程，就不抽象了，也就好理解了。
至于两样本，如果是paired的话，那就是paired之间相减，用差值做单样本t检验。如果不是成对，那就是t=(mean(x1)-mean(x2))/SEDM.
其中SEDM代表standard error of difference of means，这里有一个pool与否的问题，SEDM看上去稍微复杂了一点点，但是basic idea是一样的，非常好理解。</description>
    </item>
    
    <item>
      <title>enrichment analysis</title>
      <link>https://guangchuangyu.github.io/2012/04/enrichment-analysis/</link>
      <pubDate>Sat, 28 Apr 2012 08:06:05 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2012/04/enrichment-analysis/</guid>
      <description>&lt;p&gt;经常看到一些饼图，描述某些事物的组成，比如说有钱人的学历分布，然后我们可以看到高学历所占比例并不高，根据这个比例下结论通常是错的，这些比例说明不了问题，如果把各种学历在总体人口中的分布做为背景进行考虑的话，你就会发现学历还是有点用的。
当我们用组学测定了一大堆分子之后，我们希望站在更高的角度去看这些分子和那些生物学过程相关。那么通常各种注释，对这些基因/蛋白进行分类，那么从分类的比例上，是不能草率下结论，正如上面有钱人学历分布的例子一样。我们需要把总体的分布考虑进去。
和某个注释/分类是否有相关性，把基因分成属于这一类，和不属于这一类两种，这就好比经典统计学中的白球和黑球的抽样问题。也可以列一个２x２的表，进行独立性分析。
以文章&lt;a href=&#34;http://cancerres.aacrjournals.org/content/62/16/4722&#34;&gt;Gene Expression in Ovarian Cancer Reflects Both Morphology and Biological Behavior, Distinguishing Clear Cell from Other Poor-Prognosis Ovarian Carcinomas&lt;/a&gt;所鉴定的差异基因为例。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Support Vector Machine</title>
      <link>https://guangchuangyu.github.io/2012/04/support-vector-machine/</link>
      <pubDate>Thu, 12 Apr 2012 05:37:55 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2012/04/support-vector-machine/</guid>
      <description>&lt;p&gt;支持向量机(Support Vector Machines, SVM)最初由Vladimir
Vapnik于1997年提出，SVM最简单的形式就是找出一下区分界限（descision
boundary），也称之为超平面(hyperplane)，使得离它最近的点（称之为support
vectors）与之间隔最大。
&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2012/04/linearSVM.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;这和logistic regression有些相似，区别在于logistic
regression要求所有的点尽可能地远离中间那条线，而SVM是要求最接近中间线的点尽可能地远离中间线。也就是说SVM的主要目标是区分那些最难区分的点。&lt;/p&gt;
&lt;p&gt;SVM对于hyperplane的定义，在形式上和logistic regression一样,logistic
regression的decision boundary由$\theta^TX=0$确定,SVM则用$w^TX+b=0$表示,其中b相当于logistic regression中的$\theta_0$，从形式上看，两者并无区别，当然如前面所说，两者的目标不一样，logistic regression着眼于全局，SVM着眼于support
vectors。有监督算法都有label变量y，logistic
regression取值是&lt;code&gt;{0,1}&lt;/code&gt;，而SVM为了计算距离方便，取值为&lt;code&gt;{-1,1}&lt;/code&gt;。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Installing Hackintosh</title>
      <link>https://guangchuangyu.github.io/2012/03/installing-hackintosh/</link>
      <pubDate>Thu, 15 Mar 2012 04:47:26 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2012/03/installing-hackintosh/</guid>
      <description>&lt;p&gt;初中时在杂志上看到苹果的彩壳机，从此叔就开始成为了苹果的脑残粉，还在K6-2和win98那会，就在玩macintosh主题。&lt;/p&gt;
&lt;p&gt;本科时，通过&lt;a href=&#34;http://pearpc.sourceforge.net/&#34;&gt;PearPC&lt;/a&gt;来虚拟PowerPC，硬是在ATHLON XP 1700+这个破CPU上破了OS X Jaguar，那个慢啊，是无法忍受的。&lt;/p&gt;
&lt;p&gt;后来，有了一台&lt;a href=&#34;http://guangchuangyu.github.io/categories/powerbook&#34;&gt;powerbook&lt;/a&gt;，却拿它来装&lt;a href=&#34;http://guangchuangyu.github.io/2005/01/powerbook-g3%E4%B8%8A%E5%AE%89%E8%A3%85gentoo/&#34;&gt;gentoo&lt;/a&gt;和&lt;a href=&#34;http://guangchuangyu.github.io/2006/06/%E5%AE%89%E8%A3%85os9%E5%92%8Cnetbsd%E5%8F%8C%E7%B3%BB%E7%BB%9F/&#34;&gt;netbsd&lt;/a&gt;。从那里候开始，基本上就只用Linux/BSD。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>draw chinese character Jiong using ggplot2</title>
      <link>https://guangchuangyu.github.io/2012/02/draw-chinese-character-jiong-using-ggplot2/</link>
      <pubDate>Fri, 17 Feb 2012 09:26:50 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2012/02/draw-chinese-character-jiong-using-ggplot2/</guid>
      <description>&lt;p&gt;The Chinese character Jiong (囧) is now widely used for expressing ideas
or feelings such as annoyance, shock, embarrassment, awkwardness, scorn.&lt;/p&gt;
&lt;p&gt;The function plot of &lt;code&gt;y=1/(x^2-1)&lt;/code&gt; looks very similar of this symbol.&lt;/p&gt;
&lt;p&gt;I use ggplot2 to draw the symbol of Jiong.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>happy valentine</title>
      <link>https://guangchuangyu.github.io/2012/02/happy-valentine/</link>
      <pubDate>Tue, 14 Feb 2012 05:37:55 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2012/02/happy-valentine/</guid>
      <description>今天看到统计之都上的情人节心形图。
这次画的心形函数是： $ x = 16 (sin t)^3$ $ y = 13 cos t - 5 cos 2t - 2 cos 3t - cos 4t$
尝试用ggplot2来画，结果如下： 代码见Github.
类似的心形图以前也是画过的，当然这样的函数图有很多，详见http://www.mathematische-basteleien.de/heart.htm，画起来也很容易。
倒是以前画过的蝙蝠侠logo，更有成就感些。</description>
    </item>
    
    <item>
      <title>violin plot</title>
      <link>https://guangchuangyu.github.io/2012/02/violin-plot/</link>
      <pubDate>Tue, 07 Feb 2012 06:31:55 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2012/02/violin-plot/</guid>
      <description>&lt;p&gt;ggplot2 0.9.0版本将在3月1号发布，改动较大，最近bioc mailing
list也有诸多讨论，因为它导致了某些包编译出错（估计是NAMESPACE引起的）。&lt;/p&gt;
&lt;p&gt;按照hadley的说法是这是为了把他个人的项目变成一个社区项目。&lt;/p&gt;
&lt;p&gt;大多数的改动对用户来说是invisible的，用roxygen2去注释函数，核心代码使用S3重写，分离出一些特性（scales包）等。&lt;/p&gt;
&lt;p&gt;最明显的是现在画图速度变快了，不过我觉得最让人兴奋的是&lt;code&gt;guide_legend()&lt;/code&gt;和&lt;code&gt;guide_colorbar()&lt;/code&gt;两个函数，可以修改legend.&lt;/p&gt;
&lt;p&gt;画图的话，加了四个函数&lt;code&gt;geom_map()&lt;/code&gt;, &lt;code&gt;geom_raster()&lt;/code&gt;,&lt;code&gt;geom_dotplot()&lt;/code&gt;和&lt;code&gt;geom_violin()&lt;/code&gt;.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>宋词-词频</title>
      <link>https://guangchuangyu.github.io/2011/12/word-freq/</link>
      <pubDate>Fri, 09 Dec 2011 11:44:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/12/word-freq/</guid>
      <description>&lt;p&gt;最近老收到那个&lt;a href=&#34;http://www.douban.com/group/topic/23848309/&#34;&gt;“消灭”文科生的词频页面&lt;/a&gt;。好吧，我也来跟风娱乐一下
=,=&lt;/p&gt;
&lt;p&gt;对着原贴那样的题目，做为理科生，拿着随机数对着看啥的，哪好意思啊。搞几行代码才好装13。&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://guangchuangyu.github.io/blog_images/2011/12/random_word.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>R for scientific programming</title>
      <link>https://guangchuangyu.github.io/2011/09/r-for-scientific-programming/</link>
      <pubDate>Sat, 24 Sep 2011 08:57:48 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/09/r-for-scientific-programming/</guid>
      <description>&lt;p&gt;刚看完《&lt;a href=&#34;http://book.douban.com/subject/4324593/&#34;&gt;Introduction to Scientific Programming and Simulation Using R&lt;/a&gt;》这本书，&lt;/p&gt;
&lt;p&gt;第一部分是R编程入门； 第二部分是数值计算，主要是解方程，求积分和优化；第三部分是概率和统计，主要讲概率、随机变量等概念和参数估计；
第四部分是simulation，主要讲Monte Carlo积分和方差降低。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>MC积分</title>
      <link>https://guangchuangyu.github.io/2011/09/mc-integration/</link>
      <pubDate>Thu, 22 Sep 2011 06:40:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/09/mc-integration/</guid>
      <description>&lt;p&gt;Monte Carlo方法由冯·诺伊曼于二战时提出，1777年法国人布丰用此思路&lt;a href=&#34;http://guangchuangyu.github.io/cn/2011/09/monte-carlo-estimate-pi/&#34;&gt;估计pi值&lt;/a&gt;被认为是Monte
Carlo的起源，这个方法简单又快速，通过产生随机数，将数值计算问题变成随机变量的某些特征值（比如期望值）。&lt;/p&gt;
&lt;p&gt;积分运算，和&lt;a href=&#34;http://guangchuangyu.github.io/cn/2011/09/monte-carlo-estimate-pi/&#34;&gt;估计pi值&lt;/a&gt;一样，用hit
and miss法估计。&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;hit_miss &amp;lt;- function(fun, lower, upper, n=500) {
    # Monte Carlo integration using the hit and miss method
    x &amp;lt;- runif(n, lower, upper)
    f.value &amp;lt;- sapply(seq(lower, upper, 0.001), fun)
    f.min &amp;lt;- min(f.value)
    f.max &amp;lt;- max(f.value)
    y &amp;lt;- runif(n, f.min, f.max)
    hits &amp;lt;- sum(y &amp;lt;= fun(x))
    area &amp;lt;- (upper-lower) * f.min + hits/n * (upper-lower) * (f.max-f.min)
    return(area)
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;hit and miss方法收敛太慢，效率并不高，通常所说的MC积分是指下面这个方法。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Monte Carlo估计pi值</title>
      <link>https://guangchuangyu.github.io/2011/09/monte-carlo-estimate-pi/</link>
      <pubDate>Wed, 21 Sep 2011 10:40:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/09/monte-carlo-estimate-pi/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://mathfaculty.fullerton.edu/mathews/n2003/montecarlopi/MonteCarloPiMod/Images/MonteCarloPiMod_gr_11.gif&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;圆和外接正方形的面积比，是$ \frac{\pi r^2}{(2r)^2} = \frac{\pi}{4}$.&lt;/p&gt;
&lt;p&gt;通过这一比值，可以使用&lt;!-- raw HTML omitted --&gt;蒙特-卡罗方法&lt;!-- raw HTML omitted --&gt;来估计Pi，这是Monte Carlo方法的最经典的一个例子。&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;getPI &amp;lt;- function(N) {
    x &amp;lt;- runif(N)
    y &amp;lt;- runif(N)
    hits &amp;lt;- sum(sqrt(x^2+y^2) &amp;lt; 1)
    pi &amp;lt;- 4*hits/N
    return(pi)
}
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>ggplot2 Version of Figures in &lt;25 Recipes for Getting Started with R&gt;</title>
      <link>https://guangchuangyu.github.io/2011/08/ggplot2-version-of-figures-in-25-recipes-for-getting-started-with-r/</link>
      <pubDate>Tue, 16 Aug 2011 18:26:36 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/08/ggplot2-version-of-figures-in-25-recipes-for-getting-started-with-r/</guid>
      <description>&lt;p&gt;In order to provide an option to compare graphs produced by basic
internal plot function and ggplot2, I have recreated the figures in the
book, &lt;a href=&#34;http://book.douban.com/subject/5992544/&#34;&gt;25 Recipes for Getting Started with
R&lt;/a&gt;, with ggplot2.&lt;/p&gt;
&lt;p&gt;The code used to create the images is in separate paragraphs, allowing
easy comparison. &lt;strong&gt;1.16 Creating a Scatter Plot&lt;/strong&gt;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;plot(cars)
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>the batman equation</title>
      <link>https://guangchuangyu.github.io/2011/08/the-batman-equation/</link>
      <pubDate>Sat, 13 Aug 2011 17:44:42 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/08/the-batman-equation/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://www.hardocp.com/news/2011/07/29/batman_equation/&#34;&gt;HardOCP&lt;/a&gt; has
an image with an equation which apparently draws the Batman logo.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>根号2的几何作图</title>
      <link>https://guangchuangyu.github.io/2011/08/sqrt_2/</link>
      <pubDate>Fri, 12 Aug 2011 12:20:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/08/sqrt_2/</guid>
      <description>&lt;p&gt;读研时买了很多书，大部分都没时间看，&lt;a href=&#34;http://book.douban.com/subject/1320282/&#34;&gt;《什么是数学》&lt;/a&gt;就是其中的一本。
这两天翻看了一点。&lt;/p&gt;
&lt;p&gt;《第二章：数学中的数系》讲到了当年的伟大发现，一个正方形的对角线与它的边是不可公度的。而由不可公度线段，引入的无理数概念，引入负数，在17世纪都是个另人不安的事情，无理数是个巨大的飞跃，&lt;/p&gt;
&lt;p&gt;73页中的图10,给出了 $\sqrt{2}$的几何作图。&lt;/p&gt;
&lt;p&gt;我用R尝试把它画出来：&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>love function plot</title>
      <link>https://guangchuangyu.github.io/2011/08/love-function-plot/</link>
      <pubDate>Sat, 06 Aug 2011 05:37:55 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/08/love-function-plot/</guid>
      <description>今天在微博上看到这坑爹的方程： $ (x^2+y^2-1)^3 = {x^2} {y^3}$
画出来如下：
跟个屁股似的，sigh&amp;hellip;
翻出azalea的老文：http://azaleasays.com/2008/06/18/fomula-of-love/
用ggplot2画一下这个爱的方程：$17x^2-16|x|y+17y^2 = 225 $
x &amp;lt;- seq(-sqrt(17), sqrt(17), 0.001)y1 &amp;lt;- 8*abs(x)/17 + 15* sqrt(17 - x^2)/17y2 &amp;lt;- 8*abs(x)/17 - 15* sqrt(17 - x^2)/17d &amp;lt;- data.frame(x=c(x,x),y=c(y1,y2))require(ggplot2)p &amp;lt;- ggplot(d, aes(x,y))p + geom_point(color=&amp;quot;red&amp;quot;) 还可以画出红心，适合今天七夕的日子。
p + geom_line(color=&amp;quot;red&amp;quot;) 画函数图，这种事情，还是用CAS方便点。
通过maxima来画，一条指令就行，还不用解方程：
contour_plot(17*x^2-16*abs(x)*y+17*y^2-225, [x,-sqrt(17),sqrt(17)],[y,-15*sqrt(17)/17, sqrt(17)]) </description>
    </item>
    
    <item>
      <title>QQ plot</title>
      <link>https://guangchuangyu.github.io/2011/08/qq-plot/</link>
      <pubDate>Tue, 02 Aug 2011 08:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/08/qq-plot/</guid>
      <description>&lt;p&gt;虽然R提供了很多作图函数，但自己实现一下，是非常好的体验，而且能够让我们了解其中的细节。&lt;/p&gt;
&lt;p&gt;最近在读&lt;a href=&#34;http://book.douban.com/subject/4237062/&#34;&gt;＜Modern Applied Statistics With S-PLUS＞&lt;/a&gt;，115页讲到Q-Q图时，书中给出了一个Trellis的实现。（Trellis是S/S-PLUS的可视化系统，在R里的对等实现是lattice包）。&lt;/p&gt;
&lt;p&gt;我们知道一组数字，可以算4分位数，分别是25%， 50%（中位数）， 75%，它等于该组数字中所有数值由小到大排列后第X%的数字，事实上每个数字都可以对应一个X%，Q-Q图很简单，把样本数据和理论分布算出来的quantiles，画个散点图而已。分别用base graph和ggplot2实现，图中三个图分别由系统函数qqnorm，和这里定义的qqplot, qqplot2画出来。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>IBW2011</title>
      <link>https://guangchuangyu.github.io/2011/07/ibw2011/</link>
      <pubDate>Mon, 18 Jul 2011 04:26:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/07/ibw2011/</guid>
      <description>&lt;p&gt;开完了IBW这个会，感觉比较面向学生，会议前的龙星课程，倒是不错，我就冲着它的题目过去的，我想听的是概率图模型和系统生物学，结果只有最后一天，早上讲了点bayesian network，下午讲了会GSEA，BN讲的只是基本的概念，GSEA讲的内容还不到位，只讲到fisher&amp;rsquo;s test做enrichment analysis，并没有讲如何把表达量通过某些方法把它转化为统计量，再进行enrichment analysis，没有考虑表达量，是不叫GSEA的，提出GSEA的那篇PNAS文章，讲的就是expression+prior knowledge (gene set)。&lt;/p&gt;
&lt;p&gt;几天的时间，基本上是讲Hidden Markov Model用于序列比对，Prof Tang以前是在Waterman那里做post-doc，估计也是搞了很长时间的序列。我对这块兴趣不大。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>a simple gene finder</title>
      <link>https://guangchuangyu.github.io/2011/07/a-simple-gene-finder/</link>
      <pubDate>Sun, 10 Jul 2011 09:04:46 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/07/a-simple-gene-finder/</guid>
      <description>&lt;p&gt;上了几天的课，&lt;a href=&#34;http://ibw2011.fmmu.edu.cn/schedule.htm&#34;&gt;http://ibw2011.fmmu.edu.cn/schedule.htm&lt;/a&gt;
今天就上完了，只完成了project 1，想写gibbs sampling，但是没搞明白，汗。&lt;/p&gt;
&lt;p&gt;这个纯属练习用，没啥实用价值。&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Course Projects:&lt;/p&gt;
&lt;p&gt;Project 1: Implementation of a simple gene finder&lt;/p&gt;
&lt;p&gt;GOAL&lt;/p&gt;
&lt;p&gt;Build a simple codon-usage based gene finder for finding genes in
E.coli.&lt;/p&gt;
&lt;p&gt;Procedure&lt;/p&gt;
&lt;p&gt;Collect 100 gene sequences from the bacterium E. coli in the genbank
(&lt;a href=&#34;http://www.ncbi.nlm.nihh.gov&#34;&gt;http://www.ncbi.nlm.nihh.gov&lt;/a&gt;). Compute the codon usage table based on
these genes (and the translated protein sequences from them); Build a
probabilistic model based on the codon usages; Implement a random
sequence model in which the nucleotide frequency is computed from the
100 E. coli genes. For a given DNA sequence (and one selected reading
frame), compare your model with a random sequence model; Results that
you should submit:&lt;/p&gt;
&lt;p&gt;Two FASTA files for the collected 100 genes and 100 translated protein
sequences; The printed codon usage table; A program named ECgnfinder,
running with the syntax as ECgnfinder –i inputfile&lt;/p&gt;
&lt;p&gt;Inputfile stands for the name of input file, which should contain one
DNA sequence in FASTA file format; the program should be able to
report an error message if the input file is in the wrong format.&lt;/p&gt;
&lt;p&gt;The output should be printed to the standard output as (xxx stands for
the likelihood)&lt;/p&gt;
&lt;p&gt;ORF1: xxx ORF2: xxx&lt;/p&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>screen shot</title>
      <link>https://guangchuangyu.github.io/2011/06/screen-shot/</link>
      <pubDate>Tue, 28 Jun 2011 12:17:30 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/06/screen-shot/</guid>
      <description>&lt;p&gt;买了苹果机，一直放在家里没用，准备开会带去用，拿过来装几个软件。&lt;/p&gt;
&lt;p&gt;校园网用锐捷是个比较讨厌的东西。当年在华农，光这&lt;a href=&#34;http://guangchuangyu.github.io/2005/03/scau%E6%A0%A1%E5%9B%AD%E7%BD%91%E8%AE%A4%E8%AF%81/&#34;&gt;认证&lt;/a&gt;就搞了很久。&lt;/p&gt;
&lt;p&gt;现在开源的认证客户端多了，搞起来也方便了，现在在linux下用的&lt;a href=&#34;http://code.google.com/p/xmuruijie/&#34;&gt;xmuruijie&lt;/a&gt;，就比当年&lt;a href=&#34;http://guangchuangyu.github.io/2005/03/scau%E6%A0%A1%E5%9B%AD%E7%BD%91%E8%AE%A4%E8%AF%81/&#34;&gt;mystar&lt;/a&gt;好用。&lt;/p&gt;
&lt;p&gt;估计xmuruijie也是可以在苹果机上用的，依赖python，搞不好还有些modules要装，懒得去弄，搜了一下，找到&lt;a href=&#34;http://code.google.com/p/mentohust/&#34;&gt;mentohust&lt;/a&gt;，当然需要改一下mac address，用万能的ifconfig搞定。&lt;/p&gt;
&lt;p&gt;为了编译软件，必要先装xcode，这个大家伙，4G多，中午挂到吃晚饭才下完。
然后就可以装各种open source的软件。&lt;/p&gt;
&lt;p&gt;mac上有fink支持debian一样的apt-get，还有原生的macport，gentoo的portage也支持，我选择使用&lt;a href=&#34;http://guangchuangyu.github.io/categories/bsd&#34;&gt;netbsd&lt;/a&gt;的pkgsrc来安装各种开源软件。&lt;/p&gt;
&lt;p&gt;以前用过比较长时间的netbsd，用着比较顺手。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Five things biologists should know about statistics</title>
      <link>https://guangchuangyu.github.io/2011/06/five-things-biologists-should-know-about-statistics/</link>
      <pubDate>Fri, 24 Jun 2011 06:10:37 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/06/five-things-biologists-should-know-about-statistics/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://www.ebi.ac.uk/~birney/&#34;&gt;Ewan Birney&lt;/a&gt;最近的一篇博文（&lt;a href=&#34;http://genomeinformatician.blogspot.com/2011/06/five-statistical-things-i-wished-i-had.html&#34;&gt;Five statistical things I wished I had been taught 20 years ago&lt;/a&gt;
）讲述了统计对于生物学的重要性。&lt;/p&gt;
&lt;p&gt;一开始从RA Fisher讲起，说生物压根就是统计。Fisher是个农业学家，他所建立的那些统计方法，都是从生物学问题出发。&lt;/p&gt;
&lt;p&gt;Ewan所谈及的五个方面分别是：&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;1. Non parametric statistics. These are statistical tests which make a
bare minimum of assumptions of underlying distributions; in biology we
are rarely confident that we know the underlying distribution, and hand
waving about central limit theorem can only get you so far. Wherever
possible you should use a non parameteric test. This is Mann-Whitney (or
Wilcoxon if you prefer) for testing &amp;ldquo;medians&amp;rdquo; (Medians is in quotes
because this is not quite true. They test something which is closely
related to the median) of two distributions, Spearman&amp;rsquo;s Rho (rather
pearson&amp;rsquo;s r2) for correlation, and the Kruskal test rather than ANOVAs
(though if I get this right, you can&amp;rsquo;t in Kruskal do the more
sophisticated nested models you can do with ANOVA). Finally, don&amp;rsquo;t
forget the rather wonderful Kolmogorov-Smirnov (I always think it sounds
like really good vodka) test of whether two sets of observations come
from the same distribution. All of these methods have a basic theme of
doing things on the rank of items in a distribution, not the actual
level. So - if in doubt, do things on the rank of metric, rather than
the metric itself.&lt;/p&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>R package DOSE released</title>
      <link>https://guangchuangyu.github.io/2011/06/r-package-dose-released/</link>
      <pubDate>Mon, 13 Jun 2011 04:58:10 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/06/r-package-dose-released/</guid>
      <description>&lt;p&gt;Disease Ontology (DO) provides an open source ontology for the
integration of biomedical data that is associated with human disease. DO
analysis can lead to interesting discoveries that deserve further
clinical investigation.&lt;/p&gt;
&lt;p&gt;DOSE was designed for semantic similarity measure and enrichment
analysis.&lt;/p&gt;
&lt;p&gt;Four information content (IC)-based methods, proposed by Resnik, Jiang,
Lin and Schlicker, and one graph structure-based method, proposed by
Wang, were implemented. The calculation details can be referred to the
vignette of R package
&lt;a href=&#34;http://www.bioconductor.org/packages/2.9/bioc/html/GOSemSim.html&#34; title=&#34;GOSemSim&#34;&gt;GOSemSim&lt;/a&gt;.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>又虚长了一岁</title>
      <link>https://guangchuangyu.github.io/2011/05/birthday/</link>
      <pubDate>Thu, 05 May 2011 05:54:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/05/birthday/</guid>
      <description>&lt;p&gt;08年的时候，结合mRNA芯片和miRNA芯片数据，做靶标预测。某一天晚上，没睡着，想到可以通过靶标来计算miRNA的相似性，正好可以利用当时写的软件包&lt;a href=&#34;http://bioconductor.org/packages/release/bioc/html/GOSemSim.html&#34;&gt;GOSemSim&lt;/a&gt;来计算。&lt;/p&gt;
&lt;p&gt;09年看到BMC Systems Biology上有一篇文章，&lt;a href=&#34;http://www.biomedcentral.com/1752-0509/3/65&#34;&gt;利用miRNA所调控的蛋白相互作用网络对miRNA进行聚类&lt;/a&gt;，当时我就觉得，利用靶标来计算，这想法不发出去，它就不再新鲜了。&lt;/p&gt;
&lt;p&gt;记得Watson说过，科研有三大动力，其一是赶在竞争对手之前，其二用于泡妞，其三，忘记了-,-&lt;/p&gt;
&lt;p&gt;第三点和Watson对不上，所以记不住，第一是DNA双螺旋时，谁看到那个X射线衍射结果，谁拿炸药奖，Linus
Pauling当时是他们最大的竞争对手。第二点是Watson 39岁时，娶了自己的学生，19岁。&lt;/p&gt;
&lt;p&gt;08年的时候，算好了相似性矩阵，这事就一直掠着。老板压着我第一篇文章没发，这是最主要的原因，当然自己当时在搞申请，也有影响。&lt;/p&gt;
&lt;p&gt;毕业后，我想把它扔了。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>愚人节你好</title>
      <link>https://guangchuangyu.github.io/2011/04/fool-day/</link>
      <pubDate>Fri, 01 Apr 2011 10:48:09 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/04/fool-day/</guid>
      <description>&lt;p&gt;去年4月1号，发了&lt;a href=&#34;http://www.ncbi.nlm.nih.gov/pubmed/20179076&#34;&gt;第一篇SCI&lt;/a&gt;，昨天无意中发现，06年我去中科院面试时，不要我的那个实验室，竟然在同一年，&lt;a href=&#34;http://www.biomedcentral.com/1471-2164/11/704&#34;&gt;引用&lt;/a&gt;了我的文章。当年考两次中科院，结果还没考上，这是我以前耿耿于怀了很久的，都是浮云啊。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>clusterProfiler in Bioconductor 2.8</title>
      <link>https://guangchuangyu.github.io/2011/03/clusterprofiler-in-bioconductor-2.8/</link>
      <pubDate>Sun, 27 Mar 2011 04:12:46 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/03/clusterprofiler-in-bioconductor-2.8/</guid>
      <description>&lt;p&gt;In recently years, high-throughput experimental techniques such as
microarray and mass spectrometry can identify many lists of genes and
gene products. The most widely used strategy for high-throughput data
analysis is to identify different gene clusters based on their
expression profiles. Another commonly used approach is to annotate these
genes to biological knowledge, such as Gene Ontology (GO) and Kyoto
Encyclopedia of Genes and Genomes (KEGG), and identify the statistically
significantly enriched categories. These two different strategies were
implemented in many bioconductor packages, such as &lt;em&gt;Mfuzz&lt;/em&gt; and &lt;em&gt;BHC&lt;/em&gt; for
clustering analysis and &lt;em&gt;GOstats&lt;/em&gt; for GO enrichment analysis.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Single variable optimization</title>
      <link>https://guangchuangyu.github.io/2011/01/single-variable-optimization/</link>
      <pubDate>Sat, 01 Jan 2011 08:52:48 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2011/01/single-variable-optimization/</guid>
      <description>&lt;p&gt;Optimization means to seek minima or maxima of a funtion within a given defined domain.&lt;/p&gt;
&lt;p&gt;If a function reach its maxima or minima, the derivative at that point is approaching to 0. If we apply &lt;a href=&#34;https://mp.weixin.qq.com/s/qhT_sooSINjjvWpwq2d1VA&#34;&gt;Newton-Raphson method&lt;/a&gt; for root finding to &lt;code&gt;f&#39;&lt;/code&gt;, we can get the optimized &lt;code&gt;f&lt;/code&gt;.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>one-dimensional integrals</title>
      <link>https://guangchuangyu.github.io/2010/12/one-dimensional-integrals/</link>
      <pubDate>Sat, 25 Dec 2010 10:40:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2010/12/one-dimensional-integrals/</guid>
      <description>The foundamental idea of numerical integration is to estimate the area of the region in the xy-plane bounded by the graph of function f(x). The integral was esimated by dividing x into small intervals, then adds all the small approximations to give a total approximation.
Trapezoidal rule Numerical integration can be done by trapezoidal rule, simpson&amp;rsquo;s rule and quadrature rules. R has a built-in function, integrate, which performs adaptive quadrature.</description>
    </item>
    
    <item>
      <title>Root finding</title>
      <link>https://guangchuangyu.github.io/2010/12/root-finding/</link>
      <pubDate>Sat, 04 Dec 2010 10:40:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2010/12/root-finding/</guid>
      <description>&lt;p&gt;Numerical root finding methods use iteration, producing a sequence of numbers that hopefully converge towards a limits which is a root. This post only focuses four basic algorithms on root finding, and covers bisection method, fixed point method, Newton-Raphson method, and secant method.&lt;/p&gt;
&lt;p&gt;The simplest root finding algorithms is the &lt;a href=&#34;https://guangchuangyu.github.io/cn/2008/11/bisect-to-solve-equation/&#34;&gt;bisection method&lt;/a&gt;. It works when &lt;code&gt;f&lt;/code&gt; is a continuous function and it requires previous knowledge of two initial gueeses, &lt;code&gt;u&lt;/code&gt; and &lt;code&gt;v&lt;/code&gt;, such that &lt;code&gt;f(u)&lt;/code&gt; and &lt;code&gt;f(v)&lt;/code&gt; have opposite signs. This method is reliable, but converges slowly. For detail, see &lt;a href=&#34;https://guangchuangyu.github.io/cn/2008/11/bisect-to-solve-equation/&#34;&gt;https://guangchuangyu.github.io/cn/2008/11/bisect-to-solve-equation/&lt;/a&gt; .&lt;/p&gt;
&lt;p&gt;Root finding can be reduced to the problem of finding fixed points of the function &lt;code&gt;g(x) = c*f(x) +x&lt;/code&gt;, where &lt;code&gt;c&lt;/code&gt; is a non-zero constant. It is clearly that &lt;code&gt;f(a) = 0&lt;/code&gt; if and only if &lt;code&gt;g(a) = a&lt;/code&gt;. This is the so called fixed point algorithm.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Phosphoproteome profile of human lung cancer cell line A549</title>
      <link>https://guangchuangyu.github.io/2010/11/phosphoproteome-profile-of-human-lung-cancer-cell-line-a549/</link>
      <pubDate>Tue, 23 Nov 2010 02:22:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2010/11/phosphoproteome-profile-of-human-lung-cancer-cell-line-a549/</guid>
      <description>As an in vitro model for type II human lung cancer, A549 cells resist cytotoxicity via phosphorylation of proteins as demonstrated by many studies. However, to date, no large-scale phosphoproteome investigation has been conducted on A549. Here, we performed a systematical analysis of the phosphoproteome of A549 by using mass spectrometry (MS)-based strategies. This investigation led to the identification of 337 phosphorylation sites on 181 phosphoproteins. Among them, 67 phosphoproteins and 230 phosphorylation sites identified appeared to be novel with no previous characterization in lung cancer.</description>
    </item>
    
    <item>
      <title>The S3 OOP system</title>
      <link>https://guangchuangyu.github.io/2010/10/the-s3-oop-system/</link>
      <pubDate>Fri, 15 Oct 2010 07:24:30 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2010/10/the-s3-oop-system/</guid>
      <description>&lt;p&gt;R currently supports two internal OOP systems (S3 and S4), and several
others as add-on packages, such as
&lt;a href=&#34;http://cran.r-project.org/web/packages/R.oo/index.html&#34;&gt;R.oo&lt;/a&gt;, and
&lt;a href=&#34;http://www.omegahat.org/OOP/&#34;&gt;OOP&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;S3 is easy to use but not reliable enough for large software projects. The S3 system emphasize on generic functions and polymorphism. It&amp;rsquo;s a function centric system which is different from class centric system like JAVA.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>中国人民的翻墙情结</title>
      <link>https://guangchuangyu.github.io/2010/10/the-chinese-complex-of-cross-wall/</link>
      <pubDate>Mon, 11 Oct 2010 13:18:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2010/10/the-chinese-complex-of-cross-wall/</guid>
      <description>&lt;p&gt;不知道空窗期这个词是怎么来的，按照合理的推论应该是来自于西方，泊来之词。&lt;/p&gt;
&lt;p&gt;空窗期顾名思义就是没人来爬自己的窗户，引申出来就是没人来找自己约会。这个符合西方的建筑特点，西方的建筑是立体的，体现出来就是窗户多。而爬窗约会也多次出现于西方的文学和影视作品中。《红与黑》中就有于连拿着个梯子，爬窗去偷情的描写。&lt;/p&gt;
&lt;p&gt;而我们中国人的建筑是平面型的，体现在墙多，所以说，中国人的单身阶段应该称之为空墙期，意谓没人来翻墙。&lt;/p&gt;
&lt;p&gt;苏轼曾做过一首词，名谓《蝶恋花》。词中有云：&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;花褪残红青杏小。
燕子飞时，绿水人家绕。
枝上柳绵吹又少。
天涯何处无芳草。

墙里秋千墙外道。
墙外行人，墙里佳人笑。
笑渐不闻声渐悄。
多情却被无情恼。
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>Xming-windows下远程linux桌面</title>
      <link>https://guangchuangyu.github.io/2010/07/xming-windows%E4%B8%8B%E8%BF%9C%E7%A8%8Blinux%E6%A1%8C%E9%9D%A2/</link>
      <pubDate>Mon, 05 Jul 2010 07:37:09 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2010/07/xming-windows%E4%B8%8B%E8%BF%9C%E7%A8%8Blinux%E6%A1%8C%E9%9D%A2/</guid>
      <description>&lt;p&gt;机房放着台机架机，闲着也是耗电，平时偶尔用putty登上去，没有图形界面还是有些不方便。&lt;/p&gt;
&lt;p&gt;搜了一下，发现好几个软件可做这样的事，Xming是开源的，所以选择使用Xming+putty来远程连linux的桌面。&lt;/p&gt;
&lt;p&gt;试用了一下，果然不错。&lt;/p&gt;
&lt;p&gt;需要修改/etc/ssh/sshd_config，添加：&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;X11Forwrding yes
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;需要配置一下PuTTY，&lt;code&gt;Connection-SSh-X11&lt;/code&gt;中选中&lt;code&gt;Enable X11forwarding&lt;/code&gt;
其中&lt;code&gt;X display location&lt;/code&gt;里填入&lt;code&gt;localhost:0&lt;/code&gt;。&lt;/p&gt;
&lt;p&gt;运行Xming，再用putty连到服务器上，运行程序，就OK了。就好像windows下的本地程序一般。整合性很好。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>GOSemSim an R package for measuring semantic similarity among GO terms and gene products</title>
      <link>https://guangchuangyu.github.io/2010/05/gosemsim-an-r-package-for-measuring-semantic-similarity-among-go-terms-and-gene-products/</link>
      <pubDate>Fri, 28 May 2010 05:06:26 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2010/05/gosemsim-an-r-package-for-measuring-semantic-similarity-among-go-terms-and-gene-products/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;http://www.ncbi.nlm.nih.gov/pubmed/20179076&#34;&gt;&lt;img src=&#34;http://bioinformatics.oxfordjournals.org/content/26/18.cover.gif&#34; alt=&#34;&#34; title=&#34;bioinfo&#34;&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h3 id=&#34;abstract&#34;&gt;Abstract&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;SUMMARY&lt;/strong&gt;: The semantic comparisons of Gene Ontology (GO) annotations
provide quantitative ways to compute similarities between genes and gene
groups, and have became important basis for many bioinformatics analysis
approaches. GOSemSim is an R package for semantic similarity computation
among GO terms, sets of GO terms, gene products and gene clusters. Four
information content (IC)- and a graph-based methods are implemented in
the GOSemSim package, multiple species including human, rat, mouse, fly
and yeast are also supported. The functions provided by the GOSemSim
offer flexibility for applications, and can be easily integrated into
high-throughput analysis pipelines. AVAILABILITY: GOSemSim is released
under the GNU General Public License within Bioconductor project, and
freely available at
&lt;a href=&#34;http://bioconductor.org/packages/2.6/bioc/html/GOSemSim.html&#34;&gt;http://bioconductor.org/packages/2.6/bioc/html/GOSemSim.html&lt;/a&gt;.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Bootstrap Method</title>
      <link>https://guangchuangyu.github.io/2009/07/bootstrap-method/</link>
      <pubDate>Fri, 31 Jul 2009 09:14:42 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2009/07/bootstrap-method/</guid>
      <description>&lt;p&gt;[bootstrap](&lt;a href=&#34;http://en.wikipedia.org/wiki/Bootstrapping_(statistics&#34;&gt;http://en.wikipedia.org/wiki/Bootstrapping_(statistics&lt;/a&gt;))是对观测数据集进行有放回（replacement）的随机抽样，以评估总体的各项统计指标。可以用于假设检验、参数估计。好处是并不要求大样本，也不要求正态数据，并且对于不同的统计指标使用的是同样的计算方法。结果也更为可靠，坏处是计算量大。&lt;/p&gt;
&lt;p&gt;统计推断(statistical inference)是基于样本统计值的抽样分布来计算的，抽样分布需要从总体中许多的样本来计算，在只有一个样本的情况下，bootstrap对这一随机样本进行有放回的重复抽样，每一个重抽样本与原始随机样本一样大，每次计算相应的抽样的统计值，重复了N次之后，就可以计算统计值的bootstrap分布。&lt;/p&gt;
&lt;p&gt;下面做一个小小的试验：&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;a &amp;lt;- c(seq(1:10), rnorm(50))  
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;#创建一个样本，60个数据，非正态分布的，如下图&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2009/07/sample_a.png&#34; alt=&#34;&#34; title=&#34;sample_a&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>用Taylor公式估计函数值</title>
      <link>https://guangchuangyu.github.io/2009/03/estimate-function-value-by-taylor-theorem/</link>
      <pubDate>Tue, 17 Mar 2009 05:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2009/03/estimate-function-value-by-taylor-theorem/</guid>
      <description>&lt;p&gt;泰勒公式学过微积分都应该知道，可以翻wiki复习一下，&lt;a href=&#34;https://zh.wikipedia.org/wiki/%E6%B3%B0%E5%8B%92%E5%85%AC%E5%BC%8F&#34;&gt;https://zh.wikipedia.org/wiki/泰勒公式&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;用R简单实现一下：&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt; efv &amp;lt;- function(f, value, variable=&amp;quot;x&amp;quot;, a=0, eps=0.001) {
     #estimate function value using Taylor theorem
     assign(eval(variable), a)
     fv.old &amp;lt;- eval(f)
     k &amp;lt;- 1     
     repeat {
         df &amp;lt;- D(f, variable)
         if (df == 0)
             break
         fv.new &amp;lt;- fv.old + eval(df)*(value-a)^k/factorial(k)
         if (fv.new - fv.old &amp;lt; eps)
             break
         fv.old &amp;lt;- fv.new
         f &amp;lt;- df
         k &amp;lt;- k+1
     }
     return (fv.new)
 }
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>Assignment token of R</title>
      <link>https://guangchuangyu.github.io/2009/03/assignment-token-of-r/</link>
      <pubDate>Mon, 09 Mar 2009 13:35:24 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2009/03/assignment-token-of-r/</guid>
      <description>&lt;p&gt;when I recalled the &lt;em&gt;switch&lt;/em&gt; function, it always gave the first element, no matter what the parameter is.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2009/03/r-29-dev.png&#34; alt=&#34;r-29-dev&#34;&gt;&lt;/p&gt;
&lt;p&gt;when &lt;em&gt;organism&lt;/em&gt; changed to &amp;ldquo;yeast&amp;rdquo;, and called &lt;em&gt;switch&lt;/em&gt; function, &lt;em&gt;species&lt;/em&gt; supposed to be changed to &amp;ldquo;Sc&amp;rdquo;, but it remains it&amp;rsquo;s original value.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>关于编程，我的理解</title>
      <link>https://guangchuangyu.github.io/2008/12/opinion-in-programming/</link>
      <pubDate>Sun, 14 Dec 2008 09:18:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/12/opinion-in-programming/</guid>
      <description>&lt;p&gt;写给某个小朋友看，希望我的一点看法，能有用。欢迎讨论。。&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;为什么会有编程语言？&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;计算机史前有过不同的理论，但最后活下来的，只有图灵机一个模型。现在的计算机，都是基于此发展的，跟二战前那个三层楼高的计算机，没啥区别，那个机器一堆开关，人工操作。CPU做的计算也是开关的逻辑计算。所以计算机的语言是01二进制，一开一关，告诉计算机要不要发出电子脉冲。写一个程序全是01数字组成的，对于人来说是mission impossible！所以必须要有编程语言。编程语言就是为了&lt;strong&gt;抽象&lt;/strong&gt;计算机机械原理的一面。&lt;/p&gt;
&lt;p&gt;LOAD A ADD B STORE C&lt;/p&gt;
&lt;p&gt;实现两个数的加和，这是人类可读的语言，而不是一串01所组成的不可读的机器语言。&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;抽象&lt;/strong&gt;是最关键的。所有的编程语言都是为了实现抽象。越是高级的语言，抽象度越高，抽象度越高越好！&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>创建R包</title>
      <link>https://guangchuangyu.github.io/2008/12/creat-r-package/</link>
      <pubDate>Sun, 07 Dec 2008 05:23:16 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/12/creat-r-package/</guid>
      <description>&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;&amp;gt; source(&amp;quot;code.R&amp;quot;) #载入写好的代码 
&amp;gt; package.skeleton(name=&amp;quot;pkgname&amp;quot;, list=c(&amp;quot;function_name_list&amp;quot;))
# 生成R源码包的目录结构 
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;到man目录下改*.Rd文档。latex格式。这是包和函数的帮助文档。&lt;/p&gt;
&lt;p&gt;如果需要vignette文档的话。在包目录下，新建inst/doc，在里面写pkgname.Rnw文档。基本上是latex格式，不过允许你插入R代码。make的时候，会先跑代码。再自动转换成latex，再编译成pdf。&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;$ R CMD check pkgname 
# 检验代码和文档。这个很重要。通常一些小问题都能在这一步发现。 
$ R CMD build pkgname 
# 打包，源码包格式 
$ R CMD build --binary pkgname
#编译后打包，二进制格式。
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>用中值定理求根</title>
      <link>https://guangchuangyu.github.io/2008/11/bisect-to-solve-equation/</link>
      <pubDate>Tue, 25 Nov 2008 10:40:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/11/bisect-to-solve-equation/</guid>
      <description>&lt;p&gt;翻看了以前写的&lt;a href=&#34;https://guangchuangyu.github.io/cn/2007/06/newton-raphson-method/&#34;&gt;使用Newton-Raphson Method求一个数的开方&lt;/a&gt;，想到其实也可以用中值定理来实现。
中值定理：f(x)是一个连续性的函数，在[u,v]区间内，当c的值位于f(u)和f(v)之间时，至少存在一个点，满足f(x) = c 当f(u)和f(v)一正一负时，那么在[u,v]之间至少有一个根的存在，这个定理本来就是拿来证明根的存在的，但是其实也可以用来求解根。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>生物实验的基本原理</title>
      <link>https://guangchuangyu.github.io/2008/11/basic-principle-of-biological-experiment/</link>
      <pubDate>Tue, 25 Nov 2008 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/11/basic-principle-of-biological-experiment/</guid>
      <description>几年前自己总结出来的，就两个字“标记”，可以概括大部分的生物学实验的基本原理。 这个方法，中国人民老早就在用了，八仙张果老成仙那段，张果老吃的人参精，就是因为被弄了根绣花针才被捉的，还有蓝色的葫芦娃，会隐身，小时候看的，记不清怎么被捉的，肯定也是被标记了。。
生物学实验都是些看不见，摸不着的东西，所以基本上都是使用这个方法，看不见的，我们拿看的见的去标记它，测不着的或者不好测的，拿可以测容易测的去标记它。很多的实验手段，其实最初都是很简单的，为了提高灵敏度和精度，不断改进，越来越烦琐，抑或者出现了一些分支。通常这时候，最初那个简单的，最根本的东西就被人所忘记。看到的尽是表面上的细节。至少现在的书太二了，本来基本上一样的实验，阐述原理的时候被描成了两样的东西。
同位素标记，荧光标记自不用说。芯片实验也是标记，array上的spot序列是已知的，它会跟什么基因杂交，也是已知的。我们并不知道会有什么基因表达，但是当抽提的东西，跟某个spot有杂交信号的时候，我们就知道某个基因有表达。这就是标记。还有我们需要知道表达的量，这个依然不好测。同样也是使用标记，用cy3或cy5来标记，通过检测荧光的强度，就知道了表达的量。
所有的杂交实验都是标记，southern blot, northern blot, western blot都是。不管是核酸还是蛋白，不管它是用什么介质。都是用一个已知的，去标记一个未知的。通过测已知来估计未知的东西。
跑胶的时候，拿去紫外灯光下看。同样也是因为标记。DNA我们是看不到的，但是在DNA下嵌入了EB，可以在紫外灯光下看到EB，所以我们也就看到DNA。
所有的切片，都是在做标记，不管是用于光镜还是电镜，其实电镜本身和光镜是没本质区别的，因为可见光的波长范围很有限，电子也是一种波，成像原理是一样的，只是我们不能直接看到而已。使用电子是为了突破可见光的局限而已，使用光镜需要对细胞进行染色，使用电镜也是一样，不过染的不是染料，而是金属。
测蛋白，用考马斯亮蓝染。在280nm有吸收，那是因为苯环的共轭电子对。虽然不是标记上去的，但也可以这么想，反正是测一个我们已知的东西，来估计未知道的东西。
DNA测序，给四种碱基标上不同的荧光。
还记得脂肪代谢是怎么被揭开的吗？使用接了苯环的脂肪酸喂马，收集马尿去检验，因为马不能代谢苯环。所以拿苯环去标记脂肪酸。
还有那个DNA还是蛋白是遗传物质的实验，肺炎双球菌实验。分别用S和P的同位素标记蛋白和DNA。
还有一些看似不是标记的，其实也是标记，比如酵母双杂交，因为转录因子都有一个DNA-binding domain和一个RNA-binding domain，我们并不能直接检测到蛋白X和Y是否有相互作用，但我们可以表达溶合蛋白DBD-X和RBD-Y，如果XY有相互用用的话DBD和RBD就会在一起，就是一个有功能的转录因子，就可以转录报告基因，检测到报告基因，就表明了XY有相互作用，这就是标记，拿DBD和RBD去标记X和Y，通过DBD和RBD的行为去估计X和Y的行为。
DNA重组也使用标记，我们无法直接检测到是否重组了，是否在需要的位点重组了，所以使用了报告基因来做标记，检测到报告基因了，表明重组了，使用抗药基因，在加了药物的培养基上筛选，活下来的表明重组正确。当然有假阳性。抗药基因也是“标记”。
基本上绝大多数的实验原理，最根本的一个想法，就是使用一个已知的，或者容易检测的，去标记一个未知的，或是难以检测的。
实验的手段太多了，很多人搞不清原理。做实验的人，通常就是照着实验手册，一步一步在加东西而已。只要稍微思考一个，很多东西，其实不用记。细节的东西不需要记，需要的时候查就行了，当是基本的原理还是需要理解的。不然白学了。
很多人觉得生化就是一堆描述性的实验结果。其实很多东西也是不需要记的。举个例子，比如说DNA转录的时候，组蛋白会被乙酰化，这个细节很多人就是死记下来的，当然国内的书太二了，很多书没说乙酰化的位点是Arg和Lys，不过告诉这个事实，很多人还是死记下来。其实想一下，理解了，就不用记。为什么是这两个AA，而不是其它的？组蛋白之所以带正电就是因为富含这两个AA，这两个AA都有-NH，带正电，正是由于乙酰化了这两个位点，屏蔽了正电，DNA是带负电的，所以乙酰化之后正负电引力变小了，结构就松散了。有利于转录。这个东西就变得理所当然一样，根本不需要记。</description>
    </item>
    
    <item>
      <title>曝一下我的google reader</title>
      <link>https://guangchuangyu.github.io/2008/11/my-google-reader/</link>
      <pubDate>Sun, 23 Nov 2008 04:32:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/11/my-google-reader/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2008/11/rss.png&#34; alt=&#34;rss&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>生物研究=盲人摸象？</title>
      <link>https://guangchuangyu.github.io/2008/10/blind-approach/</link>
      <pubDate>Fri, 17 Oct 2008 00:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/10/blind-approach/</guid>
      <description>&lt;p&gt;今天看了一篇文章&lt;a href=&#34;http://www.ncbi.nlm.nih.gov/sites/entrez?cmd=Retrieve&amp;amp;db=PubMed&amp;amp;list_uids=12242150&#34;&gt;Can a biologist fix a radio?&lt;/a&gt;, 作者讲了个悖论，越多事实的积累，对于所研究的process理解的越少。&lt;/p&gt;
&lt;p&gt;这确实是现在的现实。许多的科研结果，其实就是便这个本来很混乱的世界更加混乱。文中还讲到了科研的淘金热。昨天我正好看到了science上的文章说impact
factor fever。当科研成为一种职业，真正对科学有热情的scientist并不多，更多的人仅仅是为了拿grant，要拿grant，就要发高分的文章，哪里好发文章，那里就有一堆人在抢。顺带一下，大家都说生物是火坑，其实学科在发展的初期，对于科研人员来说还是有利的。如果说工作的话，确实是火坑，其实生物是个暴利行业，如果你身在火海中，那是因为你处于生物链的最底层。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Educational Games</title>
      <link>https://guangchuangyu.github.io/2008/10/educational-games/</link>
      <pubDate>Mon, 06 Oct 2008 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/10/educational-games/</guid>
      <description>&lt;p&gt;You don&amp;rsquo;t have to be a genius to understand the work of the Nobel
Laureates. These games and simulations, based on Nobel Prize-awarded
achievements, will teach and inspire you while you&amp;rsquo;re having FUN!
Students, teachers and non-professionals of all ages will enjoy testing
and building their knowledge in physics, chemistry, physiology or
medicine, literature, peace and economics. So, go ahead, Explore and
Learn!&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>还原迅雷的url</title>
      <link>https://guangchuangyu.github.io/2008/10/restore-thunder-url/</link>
      <pubDate>Sun, 05 Oct 2008 05:08:02 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/10/restore-thunder-url/</guid>
      <description>&lt;p&gt;迅雷的url很恶心，硬是把你绑死在它的流氓软件上，今天试了一个用base64解码，果然用这个伎俩来欺骗用户。在原始的url前面和后面各加两个字符，然后用base64编码。写了下面一段script来还原出原始的url，这样随便用那个下载工具都可以用了。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>博客转WordPress</title>
      <link>https://guangchuangyu.github.io/2008/09/wordpress/</link>
      <pubDate>Tue, 30 Sep 2008 16:20:43 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/09/wordpress/</guid>
      <description>&lt;p&gt;找了一个叫&lt;strong&gt;博客备份软件&lt;/strong&gt;的小工具,备份了新浪和ChinaUnix上的blog,导出为RSS
2.0, sina的blog导出没问题,但是cu的blog导出后,文不对题.狂汗啊&amp;hellip;
但是生成的xml文件导入到wordpress里不成功.需要改一下才行.&lt;/p&gt;
&lt;p&gt;从导出的xml文件里,把&amp;lt;description&amp;gt;&amp;lt;![CDATA[替换成&amp;lt;content:encoded&amp;gt;&amp;lt;![CDATA[&lt;/p&gt;
&lt;p&gt;相应地把]]&amp;gt;&amp;lt;/description&amp;gt;替换成]]&amp;gt;&amp;lt;/content:encoded&amp;gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>备份苹果硬盘的数据</title>
      <link>https://guangchuangyu.github.io/2008/09/data-backup/</link>
      <pubDate>Mon, 29 Sep 2008 12:32:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/09/data-backup/</guid>
      <description>&lt;p&gt;powerbook笔记本装Mac OSX 10.2，我嫌太慢了，&lt;a href=&#34;https://guangchuangyu.github.io/cn/2005/01/powerbook-gentoo/&#34;&gt;就装了gentoo&lt;/a&gt;，所有的东西都是从软件编译，费了很长的时间，CPU太慢了。原来的硬盘只有10G，后来我又换了60G的硬盘，就是现在要备份数据的硬盘了。换硬盘的时候，没有换系统，我从livecd里进去，把系统打包，并对新硬盘进行分区。然后拆机换硬盘，还是从livecd进去，把新硬盘格式化，把原来的硬盘挂上去，把打包的系统解压到新的分区里，并初始化一些系统的设定，把用户数据拷进去。换硬盘不换系统。这个当时没记录下来。后来有一次手痒，重新编译了glibc，把其它的local都去掉，只留下中文的。可是这一次搞了有问题，系统总有点莫名其妙的问题。&lt;/p&gt;
&lt;p&gt;06年，我就想换个系统算了。找人刻了张os9.2的盘，自己刻了张netbsd的盘。&lt;a href=&#34;https://guangchuangyu.github.io/cn/2006/06/os9-netbsd-dual-boot&#34;&gt;装双系统&lt;/a&gt;。&lt;/p&gt;
&lt;p&gt;os9.2可以用微软的office 2001，还有ie5.5，不过都不是很好用。最爽的是可以用很多做图软件，photoshop,coredraw,illustrator等等啊。当年在合肥还帮很多同学处理过照片，因为6级考试要上传的图片要求是10k以下，很多人压到10k都看不清了，我用photoshop压到10k还能看清人.^_^.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>穿透院内的代理</title>
      <link>https://guangchuangyu.github.io/2008/09/ntlmaps/</link>
      <pubDate>Sun, 28 Sep 2008 10:27:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/09/ntlmaps/</guid>
      <description>&lt;p&gt;院里使用Microsoft ISA proxy作代理，我用linux，firefox可以通过代理验证，在终端export代理的环境变量也可以用。虽然很多软件不能支持认证，我也懒得理了。由于要用Cytoscape来分析蛋白相互作用网络，这个软件能支持代理却不支持NTLM认证，为了突破这个限制，只能作二级跳了，在本地设一个代理，软件通过这个代理上，而用本机代理负责去连接院内的代理并进行认证。&lt;/p&gt;
&lt;p&gt;搜了一下，发现ntlmaps这个包可以用来做认证，这个包是用python写的。&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;&amp;gt; apt-get install ntlmaps # 安装。
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;安装完就是修改配置文件&lt;code&gt;/etc/ntlmaps/server.cfg&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;设定网络监听的端口、父级代理的IP和端口、账号、密码、网域。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>教你如何藏不想被看到的日记</title>
      <link>https://guangchuangyu.github.io/2008/09/how-to-hide-diary/</link>
      <pubDate>Tue, 23 Sep 2008 12:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/09/how-to-hide-diary/</guid>
      <description>&lt;p&gt;有时候心情不好，就会写一些伤感的日记，然后过两天，再拿出来看一下，然后就删了。很经常这样。
其实可以藏起来，绝对超乎一般人的想像。不过我只在本科的时候这样藏过，大叔我不喜欢藏东西。呵呵。。。&lt;/p&gt;
&lt;p&gt;拿出来分享一下，不然烂在我肚子里，也是一无用处的。。。&lt;/p&gt;
&lt;p&gt;YMZ的事件，告诉大家一个真理，当个电脑小白是很吃亏滴。。学会藏东西是很必要的能力。。&lt;/p&gt;
&lt;p&gt;不过我不送修电脑，就是笔记本我也自己拆。。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>修改QQ登录界面</title>
      <link>https://guangchuangyu.github.io/2008/09/modify-qq-login-gui/</link>
      <pubDate>Tue, 23 Sep 2008 08:55:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/09/modify-qq-login-gui/</guid>
      <description>&lt;p&gt;闲来无聊，改了一下QQ的登录界面。
下面是下载链接，到QQ目录里替换掉原文件。修改的文件是2008正式版的，没有在别的版本下测试。&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://guangchuangyu.github.io/blog_images/uploads/2008/09/qq_ahmu.rar&#34;&gt;安医版&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2008/11/qq_ahmu.jpg&#34; alt=&#34;qq\_ahmu&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>映射codelink芯片ID</title>
      <link>https://guangchuangyu.github.io/2008/09/mapping-codelink-id/</link>
      <pubDate>Tue, 23 Sep 2008 01:18:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/09/mapping-codelink-id/</guid>
      <description>&lt;p&gt;GE公司codelink芯片(这个破产品已经停产了)上的探针ID，需要转成别的ID，看了一些在线的转换ID工具，都不支持，探针ID基本上都只支持affy的。&lt;/p&gt;
&lt;p&gt;想起了bioconductor里的biomaRt，这个包可以检索BioMart数据库，这个数据库里有N多种ID。试了一下，果然没问题。&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4&#34;&gt;&lt;code class=&#34;language-r&#34; data-lang=&#34;r&#34;&gt;&lt;span style=&#34;color:#75715e&#34;&gt;#加载biomaRt包&lt;/span&gt;
&lt;span style=&#34;color:#a6e22e&#34;&gt;library&lt;/span&gt;(biomaRt)

&lt;span style=&#34;color:#75715e&#34;&gt;#选取数据库&lt;/span&gt;
ensembl &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;useMart&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;ensembl&amp;#34;&lt;/span&gt;, dataset &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;hsapiens_gene_ensembl&amp;#34;&lt;/span&gt;)

&lt;span style=&#34;color:#75715e&#34;&gt;#获取可供检索的attribute&lt;/span&gt;
attributes&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;listAttributes&lt;/span&gt;(mart&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;ensembl)

&lt;span style=&#34;color:#75715e&#34;&gt;#看一下attributes里是否有codelink，得到以下的结果。&lt;/span&gt;
attributes&lt;span style=&#34;color:#a6e22e&#34;&gt;[grep&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;codelink&amp;#34;&lt;/span&gt;,attributes[,&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;]), ]

name description
&lt;span style=&#34;color:#ae81ff&#34;&gt;21&lt;/span&gt; codelink Codelink ID
&lt;span style=&#34;color:#75715e&#34;&gt;#再搜一下其它我想要的ID&lt;/span&gt;

&lt;span style=&#34;color:#75715e&#34;&gt;#读进含有codelink ID的文件。&lt;/span&gt;
mrna_id &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;read.table&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;mrna_id.txt&amp;#34;&lt;/span&gt;)

&lt;span style=&#34;color:#75715e&#34;&gt;#进行ID映射。&lt;/span&gt;
idmap &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;-&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;getBM&lt;/span&gt;(attributes&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;c&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;codelink&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;refseq_dna&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;external_gene_id&amp;#34;&lt;/span&gt;,
                            &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;embl&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;hgnc_id&amp;#34;&lt;/span&gt;,&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;hgnc_symbol&amp;#34;&lt;/span&gt;), 
               filters &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;codelink&amp;#34;&lt;/span&gt;, values&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;mrna_id[,&lt;span style=&#34;color:#ae81ff&#34;&gt;1&lt;/span&gt;],
               mart&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;ensembl,output&lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;list&amp;#34;&lt;/span&gt;)
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    
    <item>
      <title>在64位环境下编译32位的应用程序</title>
      <link>https://guangchuangyu.github.io/2008/09/compile-32bit-applications-in-64bit-linux/</link>
      <pubDate>Tue, 23 Sep 2008 00:18:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/09/compile-32bit-applications-in-64bit-linux/</guid>
      <description>&lt;p&gt;用PITA算法做靶标预测的时候，要用到ViennaRNA包做结构的折叠，这个包是被修改过的，原来的包在我机子上是可以装的。但是这个修改过的包编译不通过。很奇怪的错误，不知道怎么改。&lt;/p&gt;
&lt;p&gt;好在它有两个版本，64位和32位的。我弄到大型机上去编译32位的，也是出错，不过是命名空间的问题，我改两个头文件就可以通过了。最近又要算。那个大型机最近被搬走了。只能本机上做。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>通过局域网在linux下使用windows的程序</title>
      <link>https://guangchuangyu.github.io/2008/09/%E9%80%9A%E8%BF%87%E5%B1%80%E5%9F%9F%E7%BD%91%E5%9C%A8linux%E4%B8%8B%E4%BD%BF%E7%94%A8windows%E7%9A%84%E7%A8%8B%E5%BA%8F/</link>
      <pubDate>Mon, 22 Sep 2008 01:26:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/09/%E9%80%9A%E8%BF%87%E5%B1%80%E5%9F%9F%E7%BD%91%E5%9C%A8linux%E4%B8%8B%E4%BD%BF%E7%94%A8windows%E7%9A%84%E7%A8%8B%E5%BA%8F/</guid>
      <description>&lt;p&gt;用了好多年linux，现在用windows越来越少了，但是还是得用。没办法，上taobao买个东西，上网银都得用ie，有时候还得用office等其它一些软件。&lt;/p&gt;
&lt;p&gt;实验室里有台机子是做文件服务的，装的是windows 2003
server。之前使用rdesktop远程桌面，最近发现配合seamlessrdp可以让rdesktop实现更好的效果，运行windows程序，就像linux中原生程序一样。。&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;gt; [下载
&amp;gt; seamlessrdp.zip](http://www.cendio.se/files/thinlinc/seamlessrdp/seamlessrdp.zip)
&amp;gt; 解压丢在C盘。
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;在linux下运行这样的指令&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;gt; rdesktop -A -s &amp;quot;c:\\seamlessrdp/seamlessrdpshell.exe C:\\Program
&amp;gt; Files\\Internet Explorer\\iexplore.exe&amp;quot; ip:3389 -u administrator -p
&amp;gt; password
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;就可以在linux下运行服务器端的ie了。windows下所有程序都没问题。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>gtkballs -- 五子连线</title>
      <link>https://guangchuangyu.github.io/2008/09/gtkballs/</link>
      <pubDate>Sun, 21 Sep 2008 08:20:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/09/gtkballs/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2008/11/gtkballs.png&#34; alt=&#34;gtkballs&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>从概率的角度看 如何告别单身</title>
      <link>https://guangchuangyu.github.io/2008/08/88-bachelor/</link>
      <pubDate>Tue, 26 Aug 2008 15:10:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/08/88-bachelor/</guid>
      <description>&lt;p&gt;国家人口统计男人比女人多了3700万，在大学校园里更是流传着“我很丑，可是我很抢手”（女生版）、“我很帅，可是我很无奈”（男生版）。&lt;/p&gt;
&lt;p&gt;鉴于大龄猥琐男越来越盛行，以及小平同志说“让一部分人先恋起来嘛”
今日从科学的角度，让大家明白如何告别单身。
授人与鱼不如授人与渔。即使没能让你奔小康，起码也解决温饱~~~&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2008/11/xx0.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;告别单身的不二法则，三个字，“厚脸皮”，详见下面分析&lt;/p&gt;
&lt;p&gt;如果一个男人追一个女人，成功的概率只有0.2，
那么连续追6个，至少有一个成功的概率，高达0.74&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;gt; 1-0.8^6
[1] 0.737856
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;如果连续追7个的话，至少一个成功的概率将达到0.79&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;gt; 1-0.8^7
[1] 0.7902848
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;如果你不是特别差，成功的概率假如是0.3，那么连续追几个的成功概率将更高。。&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;gt; 1-0.7^6
[1] 0.882351
&amp;gt; 1-0.7^7
[1] 0.9176457
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>gperiodic:元素周期表</title>
      <link>https://guangchuangyu.github.io/2008/08/gperiodic/</link>
      <pubDate>Mon, 25 Aug 2008 06:56:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/08/gperiodic/</guid>
      <description>&lt;p&gt;推荐一个小软件，gperiodic，功能很简单，就是个元素周期表而已，可以查到各个元素的详细信息。&lt;/p&gt;
&lt;p&gt;当年初中的时候，这个表也是背过的。。那时候用方言背的，现在用普通话讲，总觉得有点别扭。。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>建索引检索fasta文件</title>
      <link>https://guangchuangyu.github.io/2008/08/retrieve-fasta-by-index/</link>
      <pubDate>Sat, 23 Aug 2008 13:35:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/08/retrieve-fasta-by-index/</guid>
      <description>&lt;p&gt;在实际应用中，尤其是sequence数据，应该尽可能避免把整个文件读入内存，文件有可能几个G甚至更大，可能引起内存崩溃。应该放在数据库里，建索引以检索数据。Bioperl有一个module,
Bio::DB::Fasta可以实现这个，这个模块在没有安装bioperl的情况下也可以单独安装使用。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>GOSemSim</title>
      <link>https://guangchuangyu.github.io/2008/08/gosemsim/</link>
      <pubDate>Mon, 11 Aug 2008 14:21:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/08/gosemsim/</guid>
      <description>&lt;p&gt;第一次写软件包，计算基因和GO的语义相似性。&lt;/p&gt;
&lt;p&gt;实现&lt;a href=&#34;http://bioinformatics.oxfordjournals.org/cgi/content/full/23/10/1274&#34;&gt;Wang&lt;/a&gt;的方法，基于GO的图结构。
以及四种基于信息含量的计算方法（Resnik, Jiang, Lin, Rel）。&lt;/p&gt;
&lt;p&gt;可以从Bioconductor下载到。
&lt;a href=&#34;http://bioconductor.org/packages/release/bioc/html/GOSemSim.html&#34;&gt;http://bioconductor.org/packages/release/bioc/html/GOSemSim.html&lt;/a&gt;
&lt;a href=&#34;http://bioconductor.org/packages/devel/bioc/html/GOSemSim.html&#34;&gt;http://bioconductor.org/packages/devel/bioc/html/GOSemSim.html&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;支持human, rat, mouse, fly, yeast, zebrafish,worm, E coli,
arabidopsis等物种。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>在linux下对NTFS进行读写</title>
      <link>https://guangchuangyu.github.io/2008/08/ntfs-3g/</link>
      <pubDate>Sat, 09 Aug 2008 04:32:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/08/ntfs-3g/</guid>
      <description>&lt;p&gt;今天发现了一个软件包叫&lt;em&gt;&lt;strong&gt;ntfs-config&lt;/strong&gt;&lt;/em&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;This program allow you to easily configure all of your NTFS devices to
allow write support via a friendly gui. For that use, it will
configure them to use the open source ntfs-3g driver. You&amp;rsquo;ll also be
able to easily disable this feature.
Homepage : &lt;a href=&#34;http://givre.cabspace.com/ntfs-config&#34;&gt;http://givre.cabspace.com/ntfs-config&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;Homepage of ntfs-3g :
&lt;a href=&#34;http://www.ntfs-3g.org/&#34;&gt;http://www.ntfs-3g.org&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;</description>
    </item>
    
    <item>
      <title>Screen使得远程终端更加有效率</title>
      <link>https://guangchuangyu.github.io/2008/08/screen%E4%BD%BF%E5%BE%97%E8%BF%9C%E7%A8%8B%E7%BB%88%E7%AB%AF%E6%9B%B4%E5%8A%A0%E6%9C%89%E6%95%88%E7%8E%87/</link>
      <pubDate>Fri, 08 Aug 2008 12:40:22 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/08/screen%E4%BD%BF%E5%BE%97%E8%BF%9C%E7%A8%8B%E7%BB%88%E7%AB%AF%E6%9B%B4%E5%8A%A0%E6%9C%89%E6%95%88%E7%8E%87/</guid>
      <description>根据主页Screen的描述
 “Screen is a full-screen window manager that multiplexes a physical terminal between several processes, typically interactive shells. Each virtual terminal provides the functions of the DEC VT100 terminal and, in addition, several control functions from the ANSI X3.64 (ISO 6429) and ISO 2022 standards (e.g., insert/delete line and support for multiple character sets). There is a scrollback history buffer for each virtual terminal and a copy-and-paste mechanism that allows the user to move text regions between windows.</description>
    </item>
    
    <item>
      <title>sequence alignment program written in R</title>
      <link>https://guangchuangyu.github.io/2008/08/sequence-alignment-program-written-in-r/</link>
      <pubDate>Thu, 07 Aug 2008 12:13:35 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2008/08/sequence-alignment-program-written-in-r/</guid>
      <description>&lt;p&gt;Sequence alignment by dynamic programming.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>screenshot</title>
      <link>https://guangchuangyu.github.io/2007/06/screenshot/</link>
      <pubDate>Sat, 16 Jun 2007 00:18:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2007/06/screenshot/</guid>
      <description>&lt;h2 id=&#34;os-92&#34;&gt;OS 9.2&lt;/h2&gt;
&lt;p&gt;&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2007/06/os9.jpg&#34; alt=&#34;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Newton-Raphson Method估算函数的根</title>
      <link>https://guangchuangyu.github.io/2007/06/newton-raphson-method/</link>
      <pubDate>Sat, 02 Jun 2007 13:53:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2007/06/newton-raphson-method/</guid>
      <description>&lt;h2 id=&#34;newton-raphson-method&#34;&gt;Newton-Raphson Method&lt;/h2&gt;
&lt;p&gt;曲线&lt;code&gt;f(x)&lt;/code&gt;有根c,取曲线上一点$(x_1,f(x_1))$, 过此点的切线交x轴$x_2$,过曲线上$(x_2,f(x_2))$的切线交x轴$x_3$，如此反复得到一个序列 $x_1,x_2,\cdot \cdot \cdot,x_n$ 逼近c值.&lt;/p&gt;
&lt;p&gt;过$(x_n,f(x_n))$的切线方程为 $y-f(x_n) = f&#39;(x_n),(x-x_n)$,假设此方程与x轴的交点为$x_{n+1}$, 即有: $0 - f(x_n) = f&#39;(x_n)(x_n+1 - x_n)$， 即$x_{n+1} = x_n - \frac{f(x_n)}{f&#39;(x_n)}$ &lt;code&gt;&amp;lt;Eq. 1&amp;gt;&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;下面利用此法来求一个数的开方。 $f(x) = x^2 - a$ 有根$\sqrt{a}$, 
由$f&#39;(x_n) = 2x_n$, 代入式&lt;code&gt;&amp;lt;Eq. 1&amp;gt;&lt;/code&gt;可得$x_{n+1} = (x_n + a/x_n)/2$; 当i -&amp;gt; INF 时, $x_i$ -&amp;gt; $\sqrt{a}$;&lt;/p&gt;
&lt;h2 id=&#34;c-implementation&#34;&gt;C implementation&lt;/h2&gt;</description>
    </item>
    
    <item>
      <title>我制作的pkgsrc</title>
      <link>https://guangchuangyu.github.io/2007/05/%E6%88%91%E5%88%B6%E4%BD%9C%E7%9A%84pkgsrc/</link>
      <pubDate>Wed, 16 May 2007 04:36:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2007/05/%E6%88%91%E5%88%B6%E4%BD%9C%E7%9A%84pkgsrc/</guid>
      <description>&lt;h2 id=&#34;xlyrics-unix下的歌词秀软件&#34;&gt;xlyrics: unix下的歌词秀软件   &lt;/h2&gt;
&lt;p&gt;&lt;a href=&#34;http://files.getdropbox.com/u/774072/software/pkgsrc/xlyrics-0.4.6.tar.bz2&#34;&gt;点此下载&lt;/a&gt;&lt;/p&gt;
&lt;h2 id=&#34;eva-kde下的qq客户端&#34;&gt;EVA: KDE下的QQ客户端     &lt;/h2&gt;
&lt;p&gt;&lt;a href=&#34;http://files.getdropbox.com/u/774072/software/pkgsrc/eva-20070327.tar.bz2&#34;&gt;点此下载&lt;/a&gt;&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;#cd /usr/pkgsrc/wip-cn 
#tar xjvf eva.tar.bz2 
#cd eva 
#make install clean
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;就可以啦。在我的机子（NetBSD 3.0.1 macppc）上测试通过。。
更新到eva-20070327&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Edit partition table in NetBSD/macppc</title>
      <link>https://guangchuangyu.github.io/2007/05/edit-partition-netbsd-macppc/</link>
      <pubDate>Mon, 14 May 2007 04:43:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2007/05/edit-partition-netbsd-macppc/</guid>
      <description>&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;#disklabel wd0
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;可以看到原始分区如下: 7 partitions:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;#        size    offset     fstype [fsize bsize cpg/sgs]
a:  20971520  25167648     4.2BSD      0     0     0  # (Cyl.  24967*-  45772*)
b:   1048576  46139168       swap                     # (Cyl.  45772*-  46813*)
c: 117210240         0     unused      0     0        # (Cyl.      0 - 116279)
d:  25165824      1824        HFS                     # (Cyl.      1*-  24967*)
e:  28079456  89130784        HFS                     # (Cyl.  88423*- 116279)
g:  41943040  47187744     4.2BSD      0     0     0  # (Cyl.  46813*-  88423*)
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;a为netbsd的/分区，b为swap分区,c为整个硬盘，d为mac
os的系统盘。e为两系统共享分区(在os9下格式化为fat)，g为netbsd下的/home分区。
原本是两系统，os9.2一直都很少用，所以想删了，腾出空间来放数据。因为wd0d和wd0e不在连续的柱面上，所以无法将它们合并。&lt;/p&gt;
&lt;p&gt;新的分区方案如下：wd0d删了，分成两个，一个15M(需要一个HFS类型的分区来放置&lt;code&gt;ofwboot.xcf&lt;/code&gt;，因为openfirmwire不支持从netbsd分区里加载loader),剩下的作为&lt;code&gt;/home&lt;/code&gt;分区。把原来的&lt;code&gt;/home&lt;/code&gt;分区(&lt;code&gt;wd0g&lt;/code&gt;)和共享数据的分区(&lt;code&gt;wd0e&lt;/code&gt;)合并为一个分区，用于放置数据。&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;第一步，也是最关键的一步，先备份好数据。&lt;/li&gt;
&lt;/ol&gt;</description>
    </item>
    
    <item>
      <title>pkgsrc tips</title>
      <link>https://guangchuangyu.github.io/2007/05/pkgsrc-tips/</link>
      <pubDate>Mon, 14 May 2007 04:37:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2007/05/pkgsrc-tips/</guid>
      <description>&lt;h2 id=&#34;1cpuflags&#34;&gt;1.cpuflags&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;devel/cpuflags:Determine compiler flags to best target current cpu&lt;/strong&gt;&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;#cd /usr/pkgsrc/devel/cpuflags 
#make install
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;然后在/etc/mk.conf中加入:&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;.sinclude &amp;quot;/usr/pkg/share/mk/cpuflags.mk&amp;quot;
.sinclude &amp;quot;/usr/pkg/share/mk/optimize_gcc.mk&amp;quot;
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;这样make时便能够根据cpuflags进行优化编译了。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>scilab三维平面绘图</title>
      <link>https://guangchuangyu.github.io/2007/05/scilab%E4%B8%89%E7%BB%B4%E5%B9%B3%E9%9D%A2%E7%BB%98%E5%9B%BE/</link>
      <pubDate>Thu, 03 May 2007 10:27:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2007/05/scilab%E4%B8%89%E7%BB%B4%E5%B9%B3%E9%9D%A2%E7%BB%98%E5%9B%BE/</guid>
      <description>&lt;p&gt;三维绘图可以分为两大类型：矩阵型和曲面型。&lt;/p&gt;
&lt;h2 id=&#34;矩阵型&#34;&gt;矩阵型&lt;/h2&gt;
&lt;p&gt;通常是声明一个矩阵，以矩阵的长宽为x,y范围，以矩阵里面的数值为高z，
使用&lt;code&gt;plot3d(t1,t2,Z,alpha=a,theta=b)&lt;/code&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;t1:y轴方向的范围&lt;/li&gt;
&lt;li&gt;t2:x轴方向的范围&lt;/li&gt;
&lt;li&gt;Z:矩阵&lt;/li&gt;
&lt;li&gt;alpha&lt;/li&gt;
&lt;li&gt;theta参数用于指定角度，让图绘出来以某个特定的角度呈现出来。(optional)&lt;/li&gt;
&lt;/ul&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;-&amp;gt;clear -&amp;gt;A=[1 2 5 4 3;0 3 2 8 6;2 4 6 7 5;2 3 4 3 1];
-&amp;gt;t1=1:4; -&amp;gt;t2=1:5;
//plot3d1与plot3d语法类似，能够嵌入多种颜色
-&amp;gt;plot3d(t1,t2,A,alpha=45,theta=45);
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;mesh不需要边界声明， &lt;code&gt;-&amp;gt;mesh(A);&lt;/code&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>qvwm窗口管理器的windows2000主题</title>
      <link>https://guangchuangyu.github.io/2006/06/qvwm%E7%AA%97%E5%8F%A3%E7%AE%A1%E7%90%86%E5%99%A8%E7%9A%84windows2000%E4%B8%BB%E9%A2%98/</link>
      <pubDate>Sat, 24 Jun 2006 04:33:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2006/06/qvwm%E7%AA%97%E5%8F%A3%E7%AE%A1%E7%90%86%E5%99%A8%E7%9A%84windows2000%E4%B8%BB%E9%A2%98/</guid>
      <description>&lt;p&gt;&lt;em&gt;qvwm&lt;/em&gt; is a window manager for the X Window system which provides a user
experience very close to Windows 95/98. It is small and extremely fast.&lt;/p&gt;
&lt;p&gt;可从其&lt;a href=&#34;http://qvwm.sourceforge.net/index_en.html&#34;&gt;主页&lt;/a&gt;上看到它的介绍及下载源码。&lt;/p&gt;
&lt;p&gt;这是我做的一个windows2000的主题。。&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>安装os9和netbsd双系统</title>
      <link>https://guangchuangyu.github.io/2006/06/os9-netbsd-dual-boot/</link>
      <pubDate>Wed, 14 Jun 2006 04:31:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2006/06/os9-netbsd-dual-boot/</guid>
      <description>&lt;h2 id=&#34;1-分区&#34;&gt;1 分区&lt;/h2&gt;
&lt;p&gt;用MacOS X 10.2 的光盘启动，运行Disk Utility，选择“Install Mac OS
9 Disk
Drivers”不然分区将不能在OS9中使用，我一共分了5个分区，12G,10G,512M,20G,13.4G。其中12Ｇ装OS9系统，10Ｇ装netbsd系统，512Ｍ为swap分区，20Ｇ为home
分区，最后一个为fat32格式，为两个系统所共享。&lt;/p&gt;
&lt;h2 id=&#34;2-安装os9&#34;&gt;2 安装os9&lt;/h2&gt;
&lt;p&gt;开机放入os9安装光盘，按住&lt;code&gt;Ｃ&lt;/code&gt;键，由光盘启动进入os9，在光盘根目录下点安装系统。指定第一个分区，选择安装的软件，十来分钟，便装完了。重新启动，将netbsd的启动程序&lt;code&gt;ofwboot.xcf&lt;/code&gt;放在os9的根目录下。&lt;/p&gt;
&lt;h2 id=&#34;3-安装netbsd&#34;&gt;3 安装netbsd&lt;/h2&gt;</description>
    </item>
    
    <item>
      <title>在emacs里使用maxima</title>
      <link>https://guangchuangyu.github.io/2005/05/%E5%9C%A8emacs%E9%87%8C%E4%BD%BF%E7%94%A8maxima/</link>
      <pubDate>Sat, 28 May 2005 08:15:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2005/05/%E5%9C%A8emacs%E9%87%8C%E4%BD%BF%E7%94%A8maxima/</guid>
      <description>&lt;h2 id=&#34;下载imaxima&#34;&gt;下载imaxima   &lt;/h2&gt;
&lt;p&gt;&lt;a href=&#34;http://members3.jcom.home.ne.jp/imaxima/Site/Download%20and%20Install_files/imaxima-imath-0.97a.tar.gz&#34;&gt;http://members3.jcom.home.ne.jp/imaxima/Site/Download%20and%20Install_files/imaxima-imath-0.97a.tar.gz&lt;/a&gt;&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;./configure
make
sudo make install
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;进行安装。
默认将安装在/usr/local/share/emacs/site-lisp下，在~/.emacs下加入&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;(load &amp;quot;imaxima&amp;quot;)
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;启动emacs,按M-x,键入imaxima运行maxima 但是进行运算时出错。
&lt;img src=&#34;http://guangchuangyu.github.io/blog_images/2005/05/070902122953.png&#34; alt=&#34;&#34;&gt;&lt;/p&gt;
&lt;p&gt;需要breqn094包，可从&lt;a href=&#34;ftp://ftp.ams.org/pub/tex/breqn.zip&#34;&gt;ftp://ftp.ams.org/pub/tex/breqn.zip&lt;/a&gt;下载，&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;cd /usr/share/texmf/tex/latex/
sudo unzip ~/Downloads/breqn.zip
sudo texhash
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
    <item>
      <title>scau校园网认证</title>
      <link>https://guangchuangyu.github.io/2005/03/scau%E6%A0%A1%E5%9B%AD%E7%BD%91%E8%AE%A4%E8%AF%81/</link>
      <pubDate>Mon, 14 Mar 2005 04:30:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2005/03/scau%E6%A0%A1%E5%9B%AD%E7%BD%91%E8%AE%A4%E8%AF%81/</guid>
      <description>&lt;p&gt;锐捷认证。非标准的802.1认证。 我采用mystar来认证，但是不会重连。。
我自已写了个shell script来实现断线后重连。。。&lt;/p&gt;
&lt;p&gt;华农现在的校园网用锐捷认证，windows下的认证程序还行。linux下的客户端垃圾得不得了啊。。我用苹果笔记本PowerBookG3(fireware)。锐捷没有苹果下的认证客户端，于是我上不了网了，很是郁闷。。。&lt;/p&gt;
&lt;p&gt;我装了gentoo。最初尝试用qemu的user-mode来虚拟x86的指令集，再用xrgsu（锐捷linux版认证程序）提供运行所需的libs。最终xrgsu可以运行。但是找不到网卡。后面我就放弃了。&lt;/p&gt;
&lt;p&gt;拉了一个月ADSL，在一次偶然的机会我发现了mystar。mystar是用libnet＋libpcap写的，关键的代码不到200行（libnet和libpcap是平台无关的分组构造发送、分组截获C函数库）&lt;code&gt;mystar&lt;/code&gt;是网上一个叫netxray的人写的。
下面是源码&lt;code&gt;http://bbs.whnet.edu.cn/upload/mystarV0.1-src.zip&lt;/code&gt;，解压密码是&lt;code&gt;netxray&lt;/code&gt; 解压后:&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;cd mystarV0.1 
make
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;编译。&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;#修改我的ID跟password。
vim mystar.conf 
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;使用&lt;code&gt;./mystar&lt;/code&gt;运行，并且认证成功!&lt;/p&gt;
&lt;p&gt;随后我发现一个问题，就是不会自动重连，老是会断线。在mystar.conf里面有一段&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Powerbook G3上安装gentoo</title>
      <link>https://guangchuangyu.github.io/2005/01/powerbook-gentoo/</link>
      <pubDate>Fri, 14 Jan 2005 04:32:00 +0800</pubDate>
      
      <guid>https://guangchuangyu.github.io/2005/01/powerbook-gentoo/</guid>
      <description>&lt;p&gt;下面是我在PowerBook G3上安装Gentoo的全过程。。&lt;/p&gt;
&lt;p&gt;自己做一个备忘录，也给想在Powerbook上装Gentoo的做一个参考。&lt;/p&gt;
&lt;p&gt;以下为基本的安装过程，详细请参考Gentoo的文档&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;http://www.gentoo.org/doc/en/handbook/handbook-ppc.xml&#34;&gt;http://www.gentoo.org/doc/en/handbook/handbook-ppc.xml&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;基本的安装步骤如下：&lt;/p&gt;
&lt;p&gt;用2004.3LiveCD进入。&lt;/p&gt;
&lt;h2 id=&#34;1-配置网络&#34;&gt;1. 配置网络&lt;/h2&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;＃net-setup eth0
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;回答它几个问题就行了。&lt;/p&gt;
&lt;h2 id=&#34;2分区&#34;&gt;2.分区&lt;/h2&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;#mac-fdisk /dev/hda
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;以下是我的分区。&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;/dev/hda
 # type name length base ( size ) system
/dev/hda1 Apple_partition_map Apple 63 @ 1 ( 31.5k) Partition map
/dev/hda2 Apple_Bootstrap bootstrap 1600 @ 64 (800.0k) NewWorld bootblock
/dev/hda3 Apple_UNIX_SVR2 / 12582912 @ 1664 ( 6.0G) Linux native
/dev/hda4 Apple_UNIX_SVR2 swap 1048576 @ 12584576 (512.0M) Linux swap
/dev/hda5 Apple_UNIX_SVR2 /home 6007728 @ 13633152 ( 2.9G) Linux native

Block size=512, Number of Blocks=19640880
DeviceType=0x0, DeviceId=0x0
&lt;/code&gt;&lt;/pre&gt;</description>
    </item>
    
  </channel>
</rss>
