Gantt Chart like rectangles with log scalePoets of the 19th centuryIs there a way to output histogram x and y...

How to change two letters closest to a string and one letter immediately after a string using notepad++

How to simplify this time periods definition interface?

Happy pi day, everyone!

Existence of subset with given Hausdorff dimension

A sequence that has integer values for prime indexes only:

How Could an Airship Be Repaired Mid-Flight

Are ETF trackers fundamentally better than individual stocks?

How to deal with taxi scam when on vacation?

Should we release the security issues we found in our product as CVE or we can just update those on weekly release notes?

In a future war, an old lady is trying to raise a boy but one of the weapons has made everyone deaf

How to explain that I do not want to visit a country due to personal safety concern?

Use of undefined constant bloginfo

How can I track script which gives me "command not found" right after the login?

A limit with limit zero everywhere must be zero somewhere

Python if-else code style for reduced code for rounding floats

Interplanetary conflict, some disease destroys the ability to understand or appreciate music

Define, (actually define) the "stability" and "energy" of a compound

Why one should not leave fingerprints on bulbs and plugs?

A link redirect to http instead of https: how critical is it?

What is the significance behind "40 days" that often appears in the Bible?

Unexpected result from ArcLength

What did Alexander Pope mean by "Expletives their feeble Aid do join"?

Recruiter wants very extensive technical details about all of my previous work

Are there other languages, besides English, where the indefinite (or definite) article varies based on sound?



Gantt Chart like rectangles with log scale


Poets of the 19th centuryIs there a way to output histogram x and y data without using the Histogram chart function?BarChart and Log Scale results in different bar originsIssue with ListDensityPlot when using logarithmic scaleHow to plot BarChart with error bars on logarithmic scale in Mathematica 9?How to plot two y axis? or combine(merge) two plots? Should handle faceted column as wellJumping from one dimension (1D) to two dimensions (2D)Jumping from one dimension (1D) to two dimensions (2D) Part IIWavelet Data Visualization (modus and phase) ListPlotBar chart scale in multi-chart visualisationUpdate: Combining DistributionChart and BoxWhiskerChart













3












$begingroup$


I need to plot something that looks like a gant chart, but are actual data ranges. These ranges need to be on a log scale. Graphics does not offer a Scalingfunction. A LogPlot with ErrorBars does not work either and would not look ideal. Is it possible to draw rectangles with one axis being log scale?



E.g.:
Min and Max values of the rectangles are the known data.



enter image description here










share|improve this question











$endgroup$








  • 1




    $begingroup$
    Can you point to an example (even a non-Mathematica example)?
    $endgroup$
    – David G. Stork
    3 hours ago
















3












$begingroup$


I need to plot something that looks like a gant chart, but are actual data ranges. These ranges need to be on a log scale. Graphics does not offer a Scalingfunction. A LogPlot with ErrorBars does not work either and would not look ideal. Is it possible to draw rectangles with one axis being log scale?



E.g.:
Min and Max values of the rectangles are the known data.



enter image description here










share|improve this question











$endgroup$








  • 1




    $begingroup$
    Can you point to an example (even a non-Mathematica example)?
    $endgroup$
    – David G. Stork
    3 hours ago














3












3








3





$begingroup$


I need to plot something that looks like a gant chart, but are actual data ranges. These ranges need to be on a log scale. Graphics does not offer a Scalingfunction. A LogPlot with ErrorBars does not work either and would not look ideal. Is it possible to draw rectangles with one axis being log scale?



E.g.:
Min and Max values of the rectangles are the known data.



enter image description here










share|improve this question











$endgroup$




I need to plot something that looks like a gant chart, but are actual data ranges. These ranges need to be on a log scale. Graphics does not offer a Scalingfunction. A LogPlot with ErrorBars does not work either and would not look ideal. Is it possible to draw rectangles with one axis being log scale?



E.g.:
Min and Max values of the rectangles are the known data.



enter image description here







plotting charts






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited 3 hours ago







Mockup Dungeon

















asked 3 hours ago









Mockup DungeonMockup Dungeon

878613




878613








  • 1




    $begingroup$
    Can you point to an example (even a non-Mathematica example)?
    $endgroup$
    – David G. Stork
    3 hours ago














  • 1




    $begingroup$
    Can you point to an example (even a non-Mathematica example)?
    $endgroup$
    – David G. Stork
    3 hours ago








1




1




$begingroup$
Can you point to an example (even a non-Mathematica example)?
$endgroup$
– David G. Stork
3 hours ago




$begingroup$
Can you point to an example (even a non-Mathematica example)?
$endgroup$
– David G. Stork
3 hours ago










3 Answers
3






active

oldest

votes


















3












$begingroup$

LogLinearPlot[1, 
{t, .1, 100},
PlotStyle -> White,
Epilog -> {Rectangle[{Log[1], .5}, {Log[50], 1}],
Red, Rectangle[{Log[30], 1.5}, {Log[80], 2}],
Text[Style["a", White, 18], {Log[7], .75}],
Text[Style["b", White, 18], {Log[53], 1.75}]}]





share|improve this answer











$endgroup$













  • $begingroup$
    This is nice, was wondering how to use Rectangle[]. Thank you!
    $endgroup$
    – mjw
    2 hours ago



















3












$begingroup$

SeedRandom[1]
dates = Sort /@ RandomInteger[{10, 1000}, {5, 2}];
data = MapIndexed[Thread@{#, #2[[1]]} &, dates];
labels = CharacterRange["A", "E"];
data2 = MapIndexed[Labeled[{#, #2[[1]]}, Style[labels[[#2[[1]]]], White,
FontSize -> Scaled[.03]], Center] &, N[GeometricMean /@ dates]];


Show[ListLogLinearPlot[data,
BaseStyle -> Directive[AbsoluteThickness[40], CapForm["Butt"]],
Joined -> True, PlotRange -> {0, 6}, Frame -> True,
FrameTicks -> {{Automatic, Automatic}, {Range[100, 1000, 100], Automatic}}],
ListLogLinearPlot[data2] /. _Point :> {}]


enter image description here



Thanks: @David G. Stork for the GeometricMean idea to center the labels.



See also: Poets of the 19th century






share|improve this answer











$endgroup$









  • 1




    $begingroup$
    The only needed improvement: take the geometric mean of each bar's endpoints to get the "middle" placement of the letter. Mean is simply incorrect. Try GeometricMean.
    $endgroup$
    – David G. Stork
    2 hours ago












  • $begingroup$
    Thank you @David! I was struggling with exactly that issue.
    $endgroup$
    – kglr
    2 hours ago



















0












$begingroup$

Here is a start ...



A = 10^5; B = 10; 
rectangle[start_, length_, number_] := RegionPlot[Log10[start] <= x <= Log10[start + length] && number <= y <= number + .75, {x, 0, Log10[A]}, {y, 0, B}];


Then we place a few rectangle[]'s in Show[].



Show[rectangle[100, 300, 2], rectangle[200, 2000, 3], rectangle[1300, 3000, 4], rectangle[1800, 9000, 5]]


We now need to change the tick-marks and x-axis labels. I wanted to use ScalingFunction->{"Log10",Automatic} but this is not a valid argument for RegionPlot[].



Here is how it looks right now:



enter image description here



With your edits, we can get the x-axis looking better! Currently the x-axis label is $log_{10} x $ and not $x$ as we would like.






share|improve this answer











$endgroup$













  • $begingroup$
    Axis-Ticks should not be a problem. I'll check tomorrow. It's now night here.
    $endgroup$
    – Mockup Dungeon
    2 hours ago











Your Answer





StackExchange.ifUsing("editor", function () {
return StackExchange.using("mathjaxEditing", function () {
StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix) {
StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
});
});
}, "mathjax-editing");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "387"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmathematica.stackexchange.com%2fquestions%2f193341%2fgantt-chart-like-rectangles-with-log-scale%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























3 Answers
3






active

oldest

votes








3 Answers
3






active

oldest

votes









active

oldest

votes






active

oldest

votes









3












$begingroup$

LogLinearPlot[1, 
{t, .1, 100},
PlotStyle -> White,
Epilog -> {Rectangle[{Log[1], .5}, {Log[50], 1}],
Red, Rectangle[{Log[30], 1.5}, {Log[80], 2}],
Text[Style["a", White, 18], {Log[7], .75}],
Text[Style["b", White, 18], {Log[53], 1.75}]}]





share|improve this answer











$endgroup$













  • $begingroup$
    This is nice, was wondering how to use Rectangle[]. Thank you!
    $endgroup$
    – mjw
    2 hours ago
















3












$begingroup$

LogLinearPlot[1, 
{t, .1, 100},
PlotStyle -> White,
Epilog -> {Rectangle[{Log[1], .5}, {Log[50], 1}],
Red, Rectangle[{Log[30], 1.5}, {Log[80], 2}],
Text[Style["a", White, 18], {Log[7], .75}],
Text[Style["b", White, 18], {Log[53], 1.75}]}]





share|improve this answer











$endgroup$













  • $begingroup$
    This is nice, was wondering how to use Rectangle[]. Thank you!
    $endgroup$
    – mjw
    2 hours ago














3












3








3





$begingroup$

LogLinearPlot[1, 
{t, .1, 100},
PlotStyle -> White,
Epilog -> {Rectangle[{Log[1], .5}, {Log[50], 1}],
Red, Rectangle[{Log[30], 1.5}, {Log[80], 2}],
Text[Style["a", White, 18], {Log[7], .75}],
Text[Style["b", White, 18], {Log[53], 1.75}]}]





share|improve this answer











$endgroup$



LogLinearPlot[1, 
{t, .1, 100},
PlotStyle -> White,
Epilog -> {Rectangle[{Log[1], .5}, {Log[50], 1}],
Red, Rectangle[{Log[30], 1.5}, {Log[80], 2}],
Text[Style["a", White, 18], {Log[7], .75}],
Text[Style["b", White, 18], {Log[53], 1.75}]}]






share|improve this answer














share|improve this answer



share|improve this answer








edited 2 hours ago

























answered 3 hours ago









David G. StorkDavid G. Stork

24.6k22153




24.6k22153












  • $begingroup$
    This is nice, was wondering how to use Rectangle[]. Thank you!
    $endgroup$
    – mjw
    2 hours ago


















  • $begingroup$
    This is nice, was wondering how to use Rectangle[]. Thank you!
    $endgroup$
    – mjw
    2 hours ago
















$begingroup$
This is nice, was wondering how to use Rectangle[]. Thank you!
$endgroup$
– mjw
2 hours ago




$begingroup$
This is nice, was wondering how to use Rectangle[]. Thank you!
$endgroup$
– mjw
2 hours ago











3












$begingroup$

SeedRandom[1]
dates = Sort /@ RandomInteger[{10, 1000}, {5, 2}];
data = MapIndexed[Thread@{#, #2[[1]]} &, dates];
labels = CharacterRange["A", "E"];
data2 = MapIndexed[Labeled[{#, #2[[1]]}, Style[labels[[#2[[1]]]], White,
FontSize -> Scaled[.03]], Center] &, N[GeometricMean /@ dates]];


Show[ListLogLinearPlot[data,
BaseStyle -> Directive[AbsoluteThickness[40], CapForm["Butt"]],
Joined -> True, PlotRange -> {0, 6}, Frame -> True,
FrameTicks -> {{Automatic, Automatic}, {Range[100, 1000, 100], Automatic}}],
ListLogLinearPlot[data2] /. _Point :> {}]


enter image description here



Thanks: @David G. Stork for the GeometricMean idea to center the labels.



See also: Poets of the 19th century






share|improve this answer











$endgroup$









  • 1




    $begingroup$
    The only needed improvement: take the geometric mean of each bar's endpoints to get the "middle" placement of the letter. Mean is simply incorrect. Try GeometricMean.
    $endgroup$
    – David G. Stork
    2 hours ago












  • $begingroup$
    Thank you @David! I was struggling with exactly that issue.
    $endgroup$
    – kglr
    2 hours ago
















3












$begingroup$

SeedRandom[1]
dates = Sort /@ RandomInteger[{10, 1000}, {5, 2}];
data = MapIndexed[Thread@{#, #2[[1]]} &, dates];
labels = CharacterRange["A", "E"];
data2 = MapIndexed[Labeled[{#, #2[[1]]}, Style[labels[[#2[[1]]]], White,
FontSize -> Scaled[.03]], Center] &, N[GeometricMean /@ dates]];


Show[ListLogLinearPlot[data,
BaseStyle -> Directive[AbsoluteThickness[40], CapForm["Butt"]],
Joined -> True, PlotRange -> {0, 6}, Frame -> True,
FrameTicks -> {{Automatic, Automatic}, {Range[100, 1000, 100], Automatic}}],
ListLogLinearPlot[data2] /. _Point :> {}]


enter image description here



Thanks: @David G. Stork for the GeometricMean idea to center the labels.



See also: Poets of the 19th century






share|improve this answer











$endgroup$









  • 1




    $begingroup$
    The only needed improvement: take the geometric mean of each bar's endpoints to get the "middle" placement of the letter. Mean is simply incorrect. Try GeometricMean.
    $endgroup$
    – David G. Stork
    2 hours ago












  • $begingroup$
    Thank you @David! I was struggling with exactly that issue.
    $endgroup$
    – kglr
    2 hours ago














3












3








3





$begingroup$

SeedRandom[1]
dates = Sort /@ RandomInteger[{10, 1000}, {5, 2}];
data = MapIndexed[Thread@{#, #2[[1]]} &, dates];
labels = CharacterRange["A", "E"];
data2 = MapIndexed[Labeled[{#, #2[[1]]}, Style[labels[[#2[[1]]]], White,
FontSize -> Scaled[.03]], Center] &, N[GeometricMean /@ dates]];


Show[ListLogLinearPlot[data,
BaseStyle -> Directive[AbsoluteThickness[40], CapForm["Butt"]],
Joined -> True, PlotRange -> {0, 6}, Frame -> True,
FrameTicks -> {{Automatic, Automatic}, {Range[100, 1000, 100], Automatic}}],
ListLogLinearPlot[data2] /. _Point :> {}]


enter image description here



Thanks: @David G. Stork for the GeometricMean idea to center the labels.



See also: Poets of the 19th century






share|improve this answer











$endgroup$



SeedRandom[1]
dates = Sort /@ RandomInteger[{10, 1000}, {5, 2}];
data = MapIndexed[Thread@{#, #2[[1]]} &, dates];
labels = CharacterRange["A", "E"];
data2 = MapIndexed[Labeled[{#, #2[[1]]}, Style[labels[[#2[[1]]]], White,
FontSize -> Scaled[.03]], Center] &, N[GeometricMean /@ dates]];


Show[ListLogLinearPlot[data,
BaseStyle -> Directive[AbsoluteThickness[40], CapForm["Butt"]],
Joined -> True, PlotRange -> {0, 6}, Frame -> True,
FrameTicks -> {{Automatic, Automatic}, {Range[100, 1000, 100], Automatic}}],
ListLogLinearPlot[data2] /. _Point :> {}]


enter image description here



Thanks: @David G. Stork for the GeometricMean idea to center the labels.



See also: Poets of the 19th century







share|improve this answer














share|improve this answer



share|improve this answer








edited 35 mins ago

























answered 2 hours ago









kglrkglr

189k10205422




189k10205422








  • 1




    $begingroup$
    The only needed improvement: take the geometric mean of each bar's endpoints to get the "middle" placement of the letter. Mean is simply incorrect. Try GeometricMean.
    $endgroup$
    – David G. Stork
    2 hours ago












  • $begingroup$
    Thank you @David! I was struggling with exactly that issue.
    $endgroup$
    – kglr
    2 hours ago














  • 1




    $begingroup$
    The only needed improvement: take the geometric mean of each bar's endpoints to get the "middle" placement of the letter. Mean is simply incorrect. Try GeometricMean.
    $endgroup$
    – David G. Stork
    2 hours ago












  • $begingroup$
    Thank you @David! I was struggling with exactly that issue.
    $endgroup$
    – kglr
    2 hours ago








1




1




$begingroup$
The only needed improvement: take the geometric mean of each bar's endpoints to get the "middle" placement of the letter. Mean is simply incorrect. Try GeometricMean.
$endgroup$
– David G. Stork
2 hours ago






$begingroup$
The only needed improvement: take the geometric mean of each bar's endpoints to get the "middle" placement of the letter. Mean is simply incorrect. Try GeometricMean.
$endgroup$
– David G. Stork
2 hours ago














$begingroup$
Thank you @David! I was struggling with exactly that issue.
$endgroup$
– kglr
2 hours ago




$begingroup$
Thank you @David! I was struggling with exactly that issue.
$endgroup$
– kglr
2 hours ago











0












$begingroup$

Here is a start ...



A = 10^5; B = 10; 
rectangle[start_, length_, number_] := RegionPlot[Log10[start] <= x <= Log10[start + length] && number <= y <= number + .75, {x, 0, Log10[A]}, {y, 0, B}];


Then we place a few rectangle[]'s in Show[].



Show[rectangle[100, 300, 2], rectangle[200, 2000, 3], rectangle[1300, 3000, 4], rectangle[1800, 9000, 5]]


We now need to change the tick-marks and x-axis labels. I wanted to use ScalingFunction->{"Log10",Automatic} but this is not a valid argument for RegionPlot[].



Here is how it looks right now:



enter image description here



With your edits, we can get the x-axis looking better! Currently the x-axis label is $log_{10} x $ and not $x$ as we would like.






share|improve this answer











$endgroup$













  • $begingroup$
    Axis-Ticks should not be a problem. I'll check tomorrow. It's now night here.
    $endgroup$
    – Mockup Dungeon
    2 hours ago
















0












$begingroup$

Here is a start ...



A = 10^5; B = 10; 
rectangle[start_, length_, number_] := RegionPlot[Log10[start] <= x <= Log10[start + length] && number <= y <= number + .75, {x, 0, Log10[A]}, {y, 0, B}];


Then we place a few rectangle[]'s in Show[].



Show[rectangle[100, 300, 2], rectangle[200, 2000, 3], rectangle[1300, 3000, 4], rectangle[1800, 9000, 5]]


We now need to change the tick-marks and x-axis labels. I wanted to use ScalingFunction->{"Log10",Automatic} but this is not a valid argument for RegionPlot[].



Here is how it looks right now:



enter image description here



With your edits, we can get the x-axis looking better! Currently the x-axis label is $log_{10} x $ and not $x$ as we would like.






share|improve this answer











$endgroup$













  • $begingroup$
    Axis-Ticks should not be a problem. I'll check tomorrow. It's now night here.
    $endgroup$
    – Mockup Dungeon
    2 hours ago














0












0








0





$begingroup$

Here is a start ...



A = 10^5; B = 10; 
rectangle[start_, length_, number_] := RegionPlot[Log10[start] <= x <= Log10[start + length] && number <= y <= number + .75, {x, 0, Log10[A]}, {y, 0, B}];


Then we place a few rectangle[]'s in Show[].



Show[rectangle[100, 300, 2], rectangle[200, 2000, 3], rectangle[1300, 3000, 4], rectangle[1800, 9000, 5]]


We now need to change the tick-marks and x-axis labels. I wanted to use ScalingFunction->{"Log10",Automatic} but this is not a valid argument for RegionPlot[].



Here is how it looks right now:



enter image description here



With your edits, we can get the x-axis looking better! Currently the x-axis label is $log_{10} x $ and not $x$ as we would like.






share|improve this answer











$endgroup$



Here is a start ...



A = 10^5; B = 10; 
rectangle[start_, length_, number_] := RegionPlot[Log10[start] <= x <= Log10[start + length] && number <= y <= number + .75, {x, 0, Log10[A]}, {y, 0, B}];


Then we place a few rectangle[]'s in Show[].



Show[rectangle[100, 300, 2], rectangle[200, 2000, 3], rectangle[1300, 3000, 4], rectangle[1800, 9000, 5]]


We now need to change the tick-marks and x-axis labels. I wanted to use ScalingFunction->{"Log10",Automatic} but this is not a valid argument for RegionPlot[].



Here is how it looks right now:



enter image description here



With your edits, we can get the x-axis looking better! Currently the x-axis label is $log_{10} x $ and not $x$ as we would like.







share|improve this answer














share|improve this answer



share|improve this answer








edited 3 hours ago

























answered 3 hours ago









mjwmjw

5879




5879












  • $begingroup$
    Axis-Ticks should not be a problem. I'll check tomorrow. It's now night here.
    $endgroup$
    – Mockup Dungeon
    2 hours ago


















  • $begingroup$
    Axis-Ticks should not be a problem. I'll check tomorrow. It's now night here.
    $endgroup$
    – Mockup Dungeon
    2 hours ago
















$begingroup$
Axis-Ticks should not be a problem. I'll check tomorrow. It's now night here.
$endgroup$
– Mockup Dungeon
2 hours ago




$begingroup$
Axis-Ticks should not be a problem. I'll check tomorrow. It's now night here.
$endgroup$
– Mockup Dungeon
2 hours ago


















draft saved

draft discarded




















































Thanks for contributing an answer to Mathematica Stack Exchange!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


Use MathJax to format equations. MathJax reference.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmathematica.stackexchange.com%2fquestions%2f193341%2fgantt-chart-like-rectangles-with-log-scale%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Installing LyX: “No textclass is found.”LyX installation error- text class not found- 'Reconfigure' or...

(1602) Indiana Índice Designación y nombre Características orbitales Véase...

Universidad Autónoma de Occidente Índice Historia Campus Facultades Programas Académicos Medios de...