<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Value Labels fail to display in Databricks notebook but they are displayed ok in Jupyter in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/value-labels-fail-to-display-in-databricks-notebook-but-they-are/m-p/31232#M22723</link>
    <description>&lt;P&gt;import matplotlib.pyplot as plt&lt;/P&gt;&lt;P&gt;import seaborn as sns&lt;/P&gt;&lt;P&gt;import pandas as pd&lt;/P&gt;&lt;P&gt;import numpy as np&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;prob = np.random.rand(7) + 0.1&lt;/P&gt;&lt;P&gt;prob /= prob.sum()&lt;/P&gt;&lt;P&gt;df = pd.DataFrame({'department': np.random.choice(['helium', 'neon', 'argon', 'krypton', 'xenon', 'radon', 'oganesson'],&lt;/P&gt;&lt;P&gt;                                                  1000, p=prob),&lt;/P&gt;&lt;P&gt;                   'left': np.random.choice(['yes', 'no'], 1000)})&lt;/P&gt;&lt;P&gt;with this code, I can see the value labels in my Anaconda's Jupyter however, they are not displayed in my Databricks notebook? any idea how to fix?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;import matplotlib.pyplot as plt
import seaborn as sns
import pandas as pd
import numpy as np
&amp;nbsp;
prob = np.random.rand(7) + 0.1
prob /= prob.sum()
df = pd.DataFrame({'department': np.random.choice(['helium', 'neon', 'argon', 'krypton', 'xenon', 'radon', 'oganesson'],
                                                  1000, p=prob),
                   'left': np.random.choice(['yes', 'no'], 1000)})
sns.set_style('white')
filter = df['left'] == 'yes'
g = sns.catplot(data=df[filter], kind='count', y='department', palette='mako_r',
            order=df[filter]['department'].value_counts(ascending=True).index)
for ax in g.axes.flat:
    ax.bar_label(ax.containers[0], fontsize=12)
    ax.margins(x=0.1)
plt.tight_layout()
plt.show()&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt; the bar_label attributes are used in matplotlib.pyplot version  3.4.2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am using ML runtime 7.3.  how can I upgrade?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thank you.&lt;/P&gt;</description>
    <pubDate>Fri, 21 Jan 2022 14:48:29 GMT</pubDate>
    <dc:creator>bluetail</dc:creator>
    <dc:date>2022-01-21T14:48:29Z</dc:date>
    <item>
      <title>Value Labels fail to display in Databricks notebook but they are displayed ok in Jupyter</title>
      <link>https://community.databricks.com/t5/data-engineering/value-labels-fail-to-display-in-databricks-notebook-but-they-are/m-p/31232#M22723</link>
      <description>&lt;P&gt;import matplotlib.pyplot as plt&lt;/P&gt;&lt;P&gt;import seaborn as sns&lt;/P&gt;&lt;P&gt;import pandas as pd&lt;/P&gt;&lt;P&gt;import numpy as np&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;prob = np.random.rand(7) + 0.1&lt;/P&gt;&lt;P&gt;prob /= prob.sum()&lt;/P&gt;&lt;P&gt;df = pd.DataFrame({'department': np.random.choice(['helium', 'neon', 'argon', 'krypton', 'xenon', 'radon', 'oganesson'],&lt;/P&gt;&lt;P&gt;                                                  1000, p=prob),&lt;/P&gt;&lt;P&gt;                   'left': np.random.choice(['yes', 'no'], 1000)})&lt;/P&gt;&lt;P&gt;with this code, I can see the value labels in my Anaconda's Jupyter however, they are not displayed in my Databricks notebook? any idea how to fix?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;import matplotlib.pyplot as plt
import seaborn as sns
import pandas as pd
import numpy as np
&amp;nbsp;
prob = np.random.rand(7) + 0.1
prob /= prob.sum()
df = pd.DataFrame({'department': np.random.choice(['helium', 'neon', 'argon', 'krypton', 'xenon', 'radon', 'oganesson'],
                                                  1000, p=prob),
                   'left': np.random.choice(['yes', 'no'], 1000)})
sns.set_style('white')
filter = df['left'] == 'yes'
g = sns.catplot(data=df[filter], kind='count', y='department', palette='mako_r',
            order=df[filter]['department'].value_counts(ascending=True).index)
for ax in g.axes.flat:
    ax.bar_label(ax.containers[0], fontsize=12)
    ax.margins(x=0.1)
plt.tight_layout()
plt.show()&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt; the bar_label attributes are used in matplotlib.pyplot version  3.4.2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am using ML runtime 7.3.  how can I upgrade?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thank you.&lt;/P&gt;</description>
      <pubDate>Fri, 21 Jan 2022 14:48:29 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/value-labels-fail-to-display-in-databricks-notebook-but-they-are/m-p/31232#M22723</guid>
      <dc:creator>bluetail</dc:creator>
      <dc:date>2022-01-21T14:48:29Z</dc:date>
    </item>
    <item>
      <title>Re: Value Labels fail to display in Databricks notebook but they are displayed ok in Jupyter</title>
      <link>https://community.databricks.com/t5/data-engineering/value-labels-fail-to-display-in-databricks-notebook-but-they-are/m-p/31233#M22724</link>
      <description>&lt;P&gt;Hello again! Thanks for asking. We'll wait for the community to respond before we circle back around. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We appreciate your patience. &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 21 Jan 2022 20:38:52 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/value-labels-fail-to-display-in-databricks-notebook-but-they-are/m-p/31233#M22724</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2022-01-21T20:38:52Z</dc:date>
    </item>
    <item>
      <title>Re: Value Labels fail to display in Databricks notebook but they are displayed ok in Jupyter</title>
      <link>https://community.databricks.com/t5/data-engineering/value-labels-fail-to-display-in-databricks-notebook-but-they-are/m-p/31234#M22725</link>
      <description>&lt;P&gt;You need to use the display function for plotting visualizations.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here are the docs:&lt;/P&gt;&lt;P&gt;&lt;A href="https://docs.databricks.com/notebooks/visualizations/charts-and-graphs-python.html" target="test_blank"&gt;https://docs.databricks.com/notebooks/visualizations/charts-and-graphs-python.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://docs.databricks.com/notebooks/visualizations/charts-and-graphs-python.html" target="test_blank"&gt;https://docs.databricks.com/notebooks/visualizations/charts-and-graphs-python.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To upgrade your runtime, just choose a different rundown from the cluster creation dropdown window.  &lt;/P&gt;</description>
      <pubDate>Sat, 22 Jan 2022 00:39:45 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/value-labels-fail-to-display-in-databricks-notebook-but-they-are/m-p/31234#M22725</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2022-01-22T00:39:45Z</dc:date>
    </item>
    <item>
      <title>Re: Value Labels fail to display in Databricks notebook but they are displayed ok in Jupyter</title>
      <link>https://community.databricks.com/t5/data-engineering/value-labels-fail-to-display-in-databricks-notebook-but-they-are/m-p/31235#M22726</link>
      <description>&lt;P&gt;@Maria Bruevich​&amp;nbsp;MLR 7.3 has matplotlib version 3.1.3 (you can see the contents &lt;A href="https://docs.databricks.com/release-notes/runtime/7.3ml.html?&amp;amp;_ga=2.79548881.471892635.1642880063-1439324795.1618540135#python-libraries-on-cpu-clusters" alt="https://docs.databricks.com/release-notes/runtime/7.3ml.html?&amp;amp;_ga=2.79548881.471892635.1642880063-1439324795.1618540135#python-libraries-on-cpu-clusters" target="_blank"&gt;here&lt;/A&gt;). If you upgrade to &lt;A href="https://docs.databricks.com/release-notes/runtime/9.0ml.html#python-libraries-on-cpu-clusters" alt="https://docs.databricks.com/release-notes/runtime/9.0ml.html#python-libraries-on-cpu-clusters" target="_blank"&gt;MLR 9.0&lt;/A&gt;, you will have matplotlib 3.4.2 and should not encounter any errors.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope that helps!&lt;/P&gt;</description>
      <pubDate>Sat, 22 Jan 2022 19:41:07 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/value-labels-fail-to-display-in-databricks-notebook-but-they-are/m-p/31235#M22726</guid>
      <dc:creator>austin_ford</dc:creator>
      <dc:date>2022-01-22T19:41:07Z</dc:date>
    </item>
    <item>
      <title>Re: Value Labels fail to display in Databricks notebook but they are displayed ok in Jupyter</title>
      <link>https://community.databricks.com/t5/data-engineering/value-labels-fail-to-display-in-databricks-notebook-but-they-are/m-p/31236#M22727</link>
      <description>&lt;P&gt;@Maria Bruevich​&amp;nbsp;- Do either of these answers help? If yes, would you be happy to mark one as best so that other members can find the solution more quickly?&lt;/P&gt;</description>
      <pubDate>Wed, 26 Jan 2022 16:53:48 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/value-labels-fail-to-display-in-databricks-notebook-but-they-are/m-p/31236#M22727</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2022-01-26T16:53:48Z</dc:date>
    </item>
  </channel>
</rss>

