Tableau - Conditional Background Color - charts

I am trying to construct a conditional background, based on a categorical variable, in Tableau. For example, the fed funds chart; you can see there's a line chart with two background colors. You can see that the grey extends the entire height of the chart:
http://www.alhambrapartners.com/wp-content/uploads/2012/01/FED-FUNDS-Rate-1954-to-Present-010612.png
In my data, there are 3 colors. I can get close to it by using a dual axis chart, but I can't seem to get it just right. I tried assigning a static variable, and then using the categorical as a color also, however, that doesn't really have the necessary effect.
Does anyone have any ideas?
This is the data:
https://www.dropbox.com/s/jubue3epaqct0cg/Book3.xlsx?dl=0
This is the Tableau workbook:
https://www.dropbox.com/s/753399kzm922l54/Book5.twbx?dl=0

Figured it out...displayed using a count of the categorical, and then a percentage of total.
https://public.tableausoftware.com/views/Book5_620/Sheet1?:embed=y&:display_count=no

Related

How to dynamically change the colors of filling in JavaFx 8 area chart depending on whether negative or positive values

I need a area chart that can stylize the chart fill in a different color (red, e.g.) when this be negative.
How to do it in JavaFX?
http://i.stack.imgur.com/SSl5a.png
http://i.stack.imgur.com/nzag3.png
I think the easiest way to achieve this is to create two XYCHartSeries for your Chart.
One for the negative values and one for the positives. Then you can set the color of the ChartSeries with CSS like this:
positiveChart.setId("positiveValues");
positiveChart.setStyle("#positiveValues {-fx-bar-fill: #4CAF50 }");

Area Chart with non-mixed positive and negative axis

Good morning!! I'm new to javafx charts, what im trying to do is the following, but in a single chart:
http://i.stack.imgur.com/8uF5k.jpg
The input are two arrays, one with positive values, and the other with negative values. When I mix both arrays into a single chart, this is what I get:
http://i.stack.imgur.com/dOV12.jpg
I also tried to set the color of the second data set to transparent color, with no luck.
Any ideas? Thanks!
As James_D mentioned, my problem was solved using the new prerelease of java! now it's paining the negative side of my area chart properly!

multiple stacked area charts nvd3 - errors

I am trying to create a dashboard with multiple area charts on the same page. I have two issues.
I want to get rid of the small circle on the chart that indicates value point and moves along with the cursor and the interactiveguideline. What is the name of that circle and how do I remove it?
After some research, I figured out how to change the Y-axis values to percentages. But I would like some graphs to show percentages and others to show regular numbers. Is there an easy way to do this?

Change pie chart color in Kibana

One of my uses of Kibana is related to displaying some information in certain cases only (say when a value is unexpected and exceeds a defined range). This element is therefore either shown or hidden from the dashboard, and displaying it could be considered as displaying an alert. I would prefer if the related pie chart was filled in red, rather than the default green.
Any ideas on how to do this?
Assuming you are describing Kibana 3, if you want terms panels pie charts to use different colors, you will need to make a code change.
There is a way to have custom colors for your pie chart. In order to do that you'll need to create a "hits" panel and pick the "pie chart" as the display. The color of the pie slices will be determined by the color that you chose for the queries that they track:

How can I get the size of the Plot Area in a Microsoft Chart Control

I am using the MS Chart Control in a Windows application.
I am charting various series dynamically and the user can specify which charttype each series should be. This leads to situations where pie charts are combined with line/spline charts etc..
When at least one series is specified to be a pie chart, I am dynamically adding chartareas and legends to give each of these series their own chartarea, while all the "basic" charttypes (line(area)/spline(area)/etc.) are combined into a single chartarea.
The issue is that when adding 10+ series where the majority are pie charts, the charts are resized so small, they become useless. My thought was to dynamically increase the size of the chart control (thereby increasing the size of all chartareas within). My issue is, the width and height of the InnerPlotPosition are always zero unless I set them explicitly.
Is there any way to determine the size of the Plotting Area in pixels or percentage (which I could multiply by the chart controls size to get pixels), etc. even if not explicitly set? This would allow me to increase the chart controls size until some minimum ( and hopefully, readable) value was reached.
I find that InnerPlotPosition is set at least in a PostPaint event callback. You may be checking that property before the Plot Area has been calculated.
This works:
var c = new Chart();
c.PostPaint += c_PostPaint;
// Do whatever to setup the chart
// Then in my case I'm saving the image which causes rendering
c.SaveImage(myFileName);
void c_PostPaint(object sender, ChartPaintEventArgs e)
{
var ipp = e.Chart.ChartAreas[0].InnerPlotPosition; // Values populated here
}