legend

Use Latex in Matlab legend?

ⅰ亾dé卋堺 提交于 2019-12-13 18:09:46
问题 My matlab does not accept my latex . For example if I use legend('b^{+6}\rightarrow b^{+7}') , it does not show me the arrow, How I can solve the problem? 回答1: Try with Latex interpreter, something like legend({'$b^{+6}\rightarrow b^{+7}$'}, 'interpreter', 'latex') Tested under R2012a: 回答2: For xlabel and ylabel , simply use something like: xlabel( ' $\Delta t$ [ sec ] ','Interpreter','latex') For some reason, Matlab has more difficulty with legends; you have to set the interpreter after the

Why doesn't geom_hline generate a legend in ggplot2?

筅森魡賤 提交于 2019-12-13 15:58:50
问题 I have some code that is plots a histogram of some values, along with a few horizontal lines to represent reference points to compare against. However, ggplot is not generating a legend for the lines. library(ggplot2) library(dplyr) ## Siumlate an equal mix of uniform and non-uniform observations on [0,1] x <- data.frame(PValue=c(runif(500), rbeta(500, 0.25, 1))) y <- c(Uniform=1, NullFraction=0.5) %>% data.frame(Line=names(.) %>% factor(levels=unique(.)), Intercept=.) ggplot(x) + aes(x

How to properly propagate multiplex signal names to scope legend via bus system? (Simulink)

為{幸葍}努か 提交于 2019-12-13 13:20:30
问题 I substituted my originial question, the problem is still the same, but the conditions are now different. To review the original question, have a look at the revisions. I'm looking for a way to interactively select the signals I want to get displayed in my scope Block. The Bus Selector Block with the property Output as Bus does exactly that. I can select all desired signals conveniently without changing any block or signal dimensions. But the scope block can obviously not handle properly

No legend in ggplot line graph

我的未来我决定 提交于 2019-12-13 11:03:57
问题 I am trying to generate a legend for a line graph I have created using ggplot. From what I have been reading, the legend should be made automatically given I have changed the aesthetics of the graph and included the linetype within the aes function but it is not visible. I have been scouring through answers to this exact question online and have tried many approaches but nothing seems to be working. I think I am missing something quite minor. I tried using scale_linetype_manual but this did

How to Get Dynamic Legend on Linear Graph in Loop?

谁都会走 提交于 2019-12-13 09:26:14
问题 Diff conditions: how to clear dynamic legends at the end of each iteration; how to remove fitted linear lines at the end of each iteration. I am trying to extend this answer of the thread Dynamic Legend (Updates in every recursion) to iterate legend on one graph. Proposal to cover dynamic legend on one linear graph close all; clear all; % Test data aSize=zeros(2,777); aSize=[[0, 0]' randi(3,2,777)]; % STDEV about 3 x=0:1:180; hFig=figure; index=1; while (index<=7); % origo left alone aSize(:,

Getting LEGEND tags to wrap text properly

a 夏天 提交于 2019-12-13 07:38:15
问题 Legend tags are always a nuisance as they don't adhere to a lot of CSS rules. I'm trying to get the text within a LEGEND tag to wrap using the typical solution of wrapping the text in the LEGEND with a span and setting the width and display: block. <legend> <span style="border: 1px solid blue; width: 250px; display: block"> This text should wrap if it gets longer than 250px in width </span> </legend> I thought this used to work In Firefox, but does not appear to work anymore in 3.6. Sample:

Adding legend to a radarchart in Python

别等时光非礼了梦想. 提交于 2019-12-13 07:21:29
问题 I want to create a radarchart with legends for every plot that is created but until now it has been impossible. Then, you can see the code used to create the plot (thanks to another user that developed it). import numpy as np import matplotlib.pyplot as plt import seaborn as sns # improves plot aesthetics import pandas as pd def _invert(x, limits): """inverts a value x on a scale from limits[0] to limits[1]""" return limits[1] - (x - limits[0]) def _scale_data(data, ranges): """scales data[1:

Multiple lines in histogram legend

℡╲_俬逩灬. 提交于 2019-12-13 06:36:16
问题 I am trying to plot a histogram with a legend that consists of two lines. Running the following code leads to the error: Error using matlab.graphics.chart.primitive.Histogram/set Value cell array handle dimension must match handle vector length. xErr = randn(1,1000); [mu, sig] = normfit(xErr); h = histogram(xErr, 100, 'Normalization','pdf'); % The following command causes the error set(h_xErr, {'DisplayName'}, {['Standard deviation $\sigma_{x} = $ ', num2str(sigX)]; ['Mean $\mu_x = $ ',

Legend doesn't float left on IE7

∥☆過路亽.° 提交于 2019-12-13 04:41:50
问题 I am having trouble on IE7. I have following html format. <fieldset class="wrapper"> <legend class="ct">Legend </legend> <div class="ct">Div 1</div> <div class="ct">Div 2</div> </fieldset> And this is the css style .wrapper .ct { display:inline-block; *display:inline; /*IE7*/ float:left } when I test this on other browser it works fine but IE7 does not. Please see screenshot below. But if I use div instead legend then it works. Here is on Jsfiddle 回答1: Andres almost had it. Add a "*float:

Show Values in MS Chart Legends

廉价感情. 提交于 2019-12-13 04:29:51
问题 I am trying to show the latest series value in a Legend for a FastLine type MS chart on a WinForm. I can have up to 10 series in a chart. I am using following code to add 3 columns (Symbol, Series Name, Value) in the Legend: // Add Color column LegendCellColumn firstColumn = new LegendCellColumn(); firstColumn.ColumnType = LegendCellColumnType.SeriesSymbol; firstColumn.HeaderBackColor = System.Drawing.Color.WhiteSmoke; chart1.Legends[0].CellColumns.Add(firstColumn); // Add Legend Text column