<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:clearspace="http://www.jivesoftware.com/xmlns/jive/rss" version="2.0">
  <channel>
    <title>Content in Tableau Community Forums</title>
    <link>/profile-content.jspa?filterID=contentstatus[published]&amp;targetUser=41946</link>
    <description>Recent content in Tableau Community Forums</description>
    <language>en</language>
    <pubDate>Fri, 01 Aug 2014 13:54:52 GMT</pubDate>
    <generator>Jive Engage 8.0.5.0  (http://jivesoftware.com/products/)</generator>
    <dc:date>2014-08-01T13:54:52Z</dc:date>
    <dc:language>en</dc:language>
    <item>
      <title>Conversion Rate as a Metric</title>
      <link>https://community.tableau.com/thread/146753</link>
      <description>&lt;!-- [DocumentBodyStart:7860f17c-b221-472e-8591-82ed932af997] --&gt;&lt;div class="jive-rendered-content"&gt;&lt;p&gt;Hey All,&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Kind of new to Tableau so sorry for the newbie question : )&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;B and A being two different URLs, I'm trying to define a Conversion Rate From A to B as a Metric through the calculated field feature. &lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;I managed to calculate this Conversion Rate already through the "Table Calculation" feature, but I would like to have this Metric in my "Measures" tab to be able to use it in a more flexible way. &lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;&lt;strong&gt;My data set looks like this:&lt;br/&gt;&lt;/strong&gt;&lt;/p&gt;&lt;table&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td style=";"&gt;Date&lt;/td&gt;&lt;td style=";"&gt;Marketing Type&lt;/td&gt;&lt;td style=";"&gt;Device type&lt;/td&gt;&lt;td style=";"&gt;Funnel step&lt;/td&gt;&lt;td style=";"&gt;Number of Visits&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td style=";"&gt;01-Jul-14&lt;/td&gt;&lt;td style=";"&gt;xxx&lt;/td&gt;&lt;td style=";"&gt;ppp&lt;/td&gt;&lt;td style=";"&gt;aaa&lt;/td&gt;&lt;td style=";"&gt;1150&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td style=";"&gt;01-Jul-14&lt;/td&gt;&lt;td style=";"&gt;yyy&lt;/td&gt;&lt;td style=";"&gt;mmm&lt;/td&gt;&lt;td style=";"&gt;bbb&lt;/td&gt;&lt;td style=";"&gt;120&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td style=";"&gt;01-Jul-14&lt;/td&gt;&lt;td style=";"&gt;zzz&lt;/td&gt;&lt;td style=";"&gt;nnn&lt;/td&gt;&lt;td style=";"&gt;ccc&lt;/td&gt;&lt;td style=";"&gt;16&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;My approach was to first define Conversions as Metrics, through the "Calculated Field" feature, f&lt;span style="font-size: 10pt; line-height: 1.5em;"&gt;ollowing this formula:&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;br/&gt;Conversions to aaa = &lt;span style="font-size: 10pt; line-height: 1.5em;"&gt;IF [Funnel step] = "aaa" THEN [Number of Visits] END &lt;/span&gt;&lt;/p&gt;&lt;p&gt;Conversions to bbb= &lt;span style="font-size: 10pt;"&gt;IF [Funnel step] = "bbb" THEN [Number of Visits] END &lt;/span&gt;&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Which plainly worked.&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Then I tried something like:&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Conversion Rate From aaa to bbb = Conversions to bbb / Conversions to aaa&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Which does not work at all - always NULL, as I guess,&amp;#160; ([Funnel step] = "aaa" and&amp;#160; [Funnel step] = "bbb") is never TRUE....&amp;#160; &lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;I guess I need to use some aggregation function here, but I don't know how to.&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Any idea someone ?&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Many thanks&lt;/p&gt;&lt;p style="min-height: 8pt; padding: 0px;"&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;Sabrina&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:7860f17c-b221-472e-8591-82ed932af997] --&gt;</description>
      <category domain="https://community.tableau.com/tags#/?containerType=14&amp;container=2003">calculation</category>
      <category domain="https://community.tableau.com/tags#/?containerType=14&amp;container=2003">aggregation</category>
      <pubDate>Fri, 01 Aug 2014 13:54:52 GMT</pubDate>
      <author>tableaucommunity@tableau.com</author>
      <guid>https://community.tableau.com/thread/146753</guid>
      <dc:date>2014-08-01T13:54:52Z</dc:date>
      <clearspace:dateToText>4 years 11 months ago</clearspace:dateToText>
      <clearspace:replyCount>1</clearspace:replyCount>
      <clearspace:objectType>0</clearspace:objectType>
    </item>
  </channel>
</rss>

