MathGroup Archive 2011

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: locator


I'm not sure what it is what you're asking for, but if you want to use a locator to trace a curve you can do something like

Module[{p = {0, 1}, temp},
 temp[t_] := Exp[- t];
 Row[{
   LocatorPane[Dynamic[p, (p[[2]] = temp[#[[1]]]; p[[1]] = #[[1]]) &],
     Plot[temp[t], {t, 0, 5}, PlotRange -> {Automatic, {0, 1}},
     ImageSize -> 400],
    {{0, 0}, {5, 1}}],
   Dynamic[Grid[{{"Time:", p[[1]]}, {"Temp:", p[[2]]}}]]}]]

Heike.


On 12 Jul 2011, at 11:59, raga wrote:

> hi,
> i created a front end in mathematica which provides the user the
> independence of providing the input to the code  and my code plots the
> graph for variation of temperature with time for newtons law of
> cooling but can any body please help me out by telling how to use a
> locator to locate the individual points which shows the respective
> temperature on the graph
>



  • Prev by Date: Re: Incredible slow Plot
  • Next by Date: Re: Numerical accuracy/precision - this is a bug or a feature?
  • Previous by thread: locator
  • Next by thread: Re: locator