<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	
	>
<channel>
	<title>
	Comments on: How to Change GGPlot Facet Labels	</title>
	<atom:link href="https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/</link>
	<description>Data Mining and Statistics for Decision Support</description>
	<lastBuildDate>Thu, 06 Jan 2022 14:16:15 +0000</lastBuildDate>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.8.2</generator>
	<item>
		<title>
		By: Johannes Rauh		</title>
		<link>https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-22500</link>

		<dc:creator><![CDATA[Johannes Rauh]]></dc:creator>
		<pubDate>Thu, 06 Jan 2022 14:16:15 +0000</pubDate>
		<guid isPermaLink="false">https://www.datanovia.com/en/?p=8354#comment-22500</guid>

					<description><![CDATA[Thank you, these examples are a good amendment to the documentation.

One quick comment: Instead of
```r
dose.labs &#060;- c(&#034;D0.5&#034;, &#034;D1&#034;, &#034;D2&#034;)
names(dose.labs) &#060;- c(&#034;0.5&#034;, &#034;1&#034;, &#034;2&#034;)
```
it is easier to write:
```r
dose.labs &#060;- c(&#034;0.5&#034; = &#034;D0.5&#034;, &#034;1&#034; = &#034;D1&#034;, &#034;2&#034; = &#034;D2&#034;)
```]]></description>
			<content:encoded><![CDATA[<p>Thank you, these examples are a good amendment to the documentation.</p>
<p>One quick comment: Instead of<br />
&#8220;`r<br />
dose.labs &lt;- c(&quot;D0.5&quot;, &quot;D1&quot;, &quot;D2&quot;)<br />
names(dose.labs) &lt;- c(&quot;0.5&quot;, &quot;1&quot;, &quot;2&quot;)<br />
&#8220;`<br />
it is easier to write:<br />
&#8220;`r<br />
dose.labs &lt;- c(&quot;0.5&quot; = &quot;D0.5&quot;, &quot;1&quot; = &quot;D1&quot;, &quot;2&quot; = &quot;D2&quot;)<br />
&#8220;`</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: J.C.		</title>
		<link>https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-22013</link>

		<dc:creator><![CDATA[J.C.]]></dc:creator>
		<pubDate>Sun, 16 May 2021 17:09:47 +0000</pubDate>
		<guid isPermaLink="false">https://www.datanovia.com/en/?p=8354#comment-22013</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-20975&quot;&gt;kassambara&lt;/a&gt;.

Thank you! This was a huge assist!!]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-20975">kassambara</a>.</p>
<p>Thank you! This was a huge assist!!</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: kassambara		</title>
		<link>https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-21023</link>

		<dc:creator><![CDATA[kassambara]]></dc:creator>
		<pubDate>Fri, 18 Sep 2020 17:53:13 +0000</pubDate>
		<guid isPermaLink="false">https://www.datanovia.com/en/?p=8354#comment-21023</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-21012&quot;&gt;Anand&lt;/a&gt;.

&lt;div class=&quot;rdoc&quot;&gt;
&lt;p&gt;To remove the facet labels completely, you can use something similar to the following R code:&lt;/p&gt;
&lt;pre class=&quot;r&quot;&gt;&lt;code&gt;library(ggpubr)
# Facet default 
p &#060;- ggplot(ToothGrowth, aes(x = supp, y = len)) +
  geom_boxplot() +
  theme_bw() +
  facet_wrap(~dose)
p&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;img src=&quot;https://i.imgur.com/wTP6jby.png&quot; alt=&quot;plot of chunk removing-facet-labels&quot; /&gt;&lt;/p&gt;
&lt;pre class=&quot;r&quot;&gt;&lt;code&gt;# Remove facet title
p + theme(
  strip.background = element_blank(),
  strip.text.x = element_blank()
)&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;img src=&quot;https://i.imgur.com/K2tFixU.png&quot; alt=&quot;plot of chunk removing-facet-labels&quot; /&gt;&lt;/p&gt;
&lt;/div&gt;]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-21012">Anand</a>.</p>
<div class="rdoc">
<p>To remove the facet labels completely, you can use something similar to the following R code:</p>
<pre class="r"><code>library(ggpubr)
# Facet default 
p &lt;- ggplot(ToothGrowth, aes(x = supp, y = len)) +
  geom_boxplot() +
  theme_bw() +
  facet_wrap(~dose)
p</code></pre>
<p><img src="https://i.imgur.com/wTP6jby.png" alt="plot of chunk removing-facet-labels" /></p>
<pre class="r"><code># Remove facet title
p + theme(
  strip.background = element_blank(),
  strip.text.x = element_blank()
)</code></pre>
<p><img src="https://i.imgur.com/K2tFixU.png" alt="plot of chunk removing-facet-labels" /></p>
</div>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Anand		</title>
		<link>https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-21012</link>

		<dc:creator><![CDATA[Anand]]></dc:creator>
		<pubDate>Thu, 17 Sep 2020 01:19:57 +0000</pubDate>
		<guid isPermaLink="false">https://www.datanovia.com/en/?p=8354#comment-21012</guid>

					<description><![CDATA[Hi Kassambara.
Is there a way to remove the facet plot titles completely?
Thanks.]]></description>
			<content:encoded><![CDATA[<p>Hi Kassambara.<br />
Is there a way to remove the facet plot titles completely?<br />
Thanks.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: ArkSta		</title>
		<link>https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-20978</link>

		<dc:creator><![CDATA[ArkSta]]></dc:creator>
		<pubDate>Tue, 08 Sep 2020 17:18:30 +0000</pubDate>
		<guid isPermaLink="false">https://www.datanovia.com/en/?p=8354#comment-20978</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-20977&quot;&gt;kassambara&lt;/a&gt;.

Dear Professor!

Works perfectly !!!

Again thank you very much :-)

Best regards,
Arek]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-20977">kassambara</a>.</p>
<p>Dear Professor!</p>
<p>Works perfectly !!!</p>
<p>Again thank you very much 🙂</p>
<p>Best regards,<br />
Arek</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: kassambara		</title>
		<link>https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-20977</link>

		<dc:creator><![CDATA[kassambara]]></dc:creator>
		<pubDate>Tue, 08 Sep 2020 12:16:26 +0000</pubDate>
		<guid isPermaLink="false">https://www.datanovia.com/en/?p=8354#comment-20977</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-20976&quot;&gt;ArkSta&lt;/a&gt;.

&lt;div class=&quot;rdoc&quot;&gt;
&lt;p&gt;In the current version, ggpubr doesn’t support the argument labeller = “label_parsed”, so you can go as follow:&lt;/p&gt;
&lt;pre class=&quot;r&quot;&gt;&lt;code&gt;# Plot
library(ggpubr)
ggbarplot(
  df, x = &#034;supp&#034;, y = &#034;len&#034;, add = &#034;mean_sd&#034;,
  facet.by = &#034;dose&#034;
  ) +
   facet_wrap(~dose, labeller = label_parsed)&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-20976">ArkSta</a>.</p>
<div class="rdoc">
<p>In the current version, ggpubr doesn’t support the argument labeller = “label_parsed”, so you can go as follow:</p>
<pre class="r"><code># Plot
library(ggpubr)
ggbarplot(
  df, x = &quot;supp&quot;, y = &quot;len&quot;, add = &quot;mean_sd&quot;,
  facet.by = &quot;dose&quot;
  ) +
   facet_wrap(~dose, labeller = label_parsed)</code></pre>
</div>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: ArkSta		</title>
		<link>https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-20976</link>

		<dc:creator><![CDATA[ArkSta]]></dc:creator>
		<pubDate>Tue, 08 Sep 2020 07:55:41 +0000</pubDate>
		<guid isPermaLink="false">https://www.datanovia.com/en/?p=8354#comment-20976</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-20975&quot;&gt;kassambara&lt;/a&gt;.

Thank you very much for your time and quick reply.
I have a slightly different problem because I built ggbarpolt based on the ggpubr package and then split them into panels based on the formula facet.by = &quot;xyz&quot;
In this case, is it possible to introduce special characters to the panel labels?]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-20975">kassambara</a>.</p>
<p>Thank you very much for your time and quick reply.<br />
I have a slightly different problem because I built ggbarpolt based on the ggpubr package and then split them into panels based on the formula facet.by = &#8220;xyz&#8221;<br />
In this case, is it possible to introduce special characters to the panel labels?</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: kassambara		</title>
		<link>https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-20975</link>

		<dc:creator><![CDATA[kassambara]]></dc:creator>
		<pubDate>Tue, 08 Sep 2020 05:18:11 +0000</pubDate>
		<guid isPermaLink="false">https://www.datanovia.com/en/?p=8354#comment-20975</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-20974&quot;&gt;ArkSta&lt;/a&gt;.

Hi ArkSta, thank you for the positive feedback, highly appreciated!


&lt;div class=&quot;rdoc&quot;&gt;
&lt;p&gt;You want &lt;code&gt;labeller = label_parsed&lt;/code&gt;. Here’s a simple example&lt;/p&gt;
&lt;pre class=&quot;r&quot;&gt;&lt;code&gt;# Data preparation
data(&#034;ToothGrowth&#034;)
df &#060;- ToothGrowth

df$dose &#060;- factor(
  df$dose,
  levels = c(&#034;0.5&#034;, &#034;1&#034;, &#034;2&#034;),
  labels = c(
    &#034;0.5~(mg~L^{-1})&#034;, 
    &#034;1~(mg~L^{-1})&#034;, 
    &#034;2~(mg~L^{-1})&#034;
  ))

# Plot
library(ggplot2)
ggplot(df, aes(x = supp, y = len)) + 
  geom_boxplot()+
  facet_wrap(~dose, labeller = label_parsed)&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;img src=&quot;https://i.imgur.com/gALdtZ0.png&quot; alt=&quot;plot of chunk add-superscripts-to-facet-labels&quot; /&gt;&lt;/p&gt;
&lt;/div&gt;]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-20974">ArkSta</a>.</p>
<p>Hi ArkSta, thank you for the positive feedback, highly appreciated!</p>
<div class="rdoc">
<p>You want <code>labeller = label_parsed</code>. Here’s a simple example</p>
<pre class="r"><code># Data preparation
data(&quot;ToothGrowth&quot;)
df &lt;- ToothGrowth

df$dose &lt;- factor(
  df$dose,
  levels = c(&quot;0.5&quot;, &quot;1&quot;, &quot;2&quot;),
  labels = c(
    &quot;0.5~(mg~L^{-1})&quot;, 
    &quot;1~(mg~L^{-1})&quot;, 
    &quot;2~(mg~L^{-1})&quot;
  ))

# Plot
library(ggplot2)
ggplot(df, aes(x = supp, y = len)) + 
  geom_boxplot()+
  facet_wrap(~dose, labeller = label_parsed)</code></pre>
<p><img src="https://i.imgur.com/gALdtZ0.png" alt="plot of chunk add-superscripts-to-facet-labels" /></p>
</div>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: ArkSta		</title>
		<link>https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-20974</link>

		<dc:creator><![CDATA[ArkSta]]></dc:creator>
		<pubDate>Tue, 08 Sep 2020 05:01:20 +0000</pubDate>
		<guid isPermaLink="false">https://www.datanovia.com/en/?p=8354#comment-20974</guid>

					<description><![CDATA[Dear Kassambara,
Thank you for the excellent statistics lesson and data presentation. The best tutorial I&#039;ve ever seen !!!
I have a question, is it possible to introduce special characters (e.g. superscript / subscript) to panel labels?]]></description>
			<content:encoded><![CDATA[<p>Dear Kassambara,<br />
Thank you for the excellent statistics lesson and data presentation. The best tutorial I&#8217;ve ever seen !!!<br />
I have a question, is it possible to introduce special characters (e.g. superscript / subscript) to panel labels?</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: kassambara		</title>
		<link>https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-11202</link>

		<dc:creator><![CDATA[kassambara]]></dc:creator>
		<pubDate>Sat, 04 Apr 2020 09:48:22 +0000</pubDate>
		<guid isPermaLink="false">https://www.datanovia.com/en/?p=8354#comment-11202</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-11201&quot;&gt;DinaP&lt;/a&gt;.

Thank you for your positive feedback!]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://www.datanovia.com/en/blog/how-to-change-ggplot-facet-labels/#comment-11201">DinaP</a>.</p>
<p>Thank you for your positive feedback!</p>
]]></content:encoded>
		
			</item>
	</channel>
</rss>

<!--
Performance optimized by W3 Total Cache. Learn more: https://www.boldgrid.com/w3-total-cache/

Object Caching 124/169 objects using Memcached
Page Caching using Disk: Enhanced 
Lazy Loading (feed)
Database Caching 38/54 queries in 0.038 seconds using APC

Served from: www.datanovia.com @ 2025-07-31 14:29:40 by W3 Total Cache
-->