Hi Qingshuang Di,
Am 18.04.2012 12:08, schrieb qingshuang di:
> Dear Christian,
> Thanks for your reply!
> I think the second method is what I want. Is that the \pgfplotsset{
> will define a new style?
>
Yes, the method can be used to define a new style - but more than that,
it can also change the current configuration.
More precisely, if it contains something like <key>/.style={<options>}
, it defines a *new* style named <key> which is equivalent to <options>.
So, the following defines a new style option called 'mynormal':
> I see someone use the following method
> \pgfplotsset{
> mynormal/.style={ % <--- here is the new
> defined option?
> /pgfplots/width=.95\columnwidth,
> .................
>
> \begin{tikzpicture}%
> %%\tikzset{mark options={solid}}
> \begin{semilogxaxis}[mynormal, % <--- here is the new
> defined option put?
> xlabel={x label},
> ylabel={y label},
> xmin=1E-5,
>
Yes, this is how styles are used.
> ......................
> and also, I find another option on web:
>
> \begin{tikzpicture} %
> \tikzset{mark options={solid}} %<--- this is the option I used, it
> works well.
>
Yes, that does also work. The option 'mark options={solid}' is
predefined to be equivalent to 'every mark/.append style={solid}'.
You can find documentation of \pgfplotsset in the pgfplots manual,
similarly when it comes to the other options.
Note that
\begin{tikzpicture}
\tikzset{mark options={solid}}
is COMPLETELY equivalent to
\begin{tikzpicture}[mark options={solid}] .
typically, everything in square brackets after a command or environment
is processed as if you would write \tikzset{...} (or \pgfplotsset{...},
depending on the context).
> There is another problem. In my tex, if I choose 8 point on x-axis,
> then the curve is right,
> but if I choose 10 points on x-axis, the y-value of 8th point is
> wrong. I don't know why.
>
I fear I do not quite understand what you mean... could you provide a
minimal working example which illustrates what you have done so far?
Best regards
Christian
>
>
> --- *12年4月18日,周三, Christian Feuersaenger
> /<[email protected]>/* 写道:
>
>
> 发件人: Christian Feuersaenger <[email protected]>
> 主题: Re: [pgfplots] set mark line style as solid, thanks!
> 收件人: "qingshuang di" <[email protected]>
> 抄送: "'PGFplots mailing list'"
> <[email protected]>
> 日期: 2012年4月18日,周三,上午2:47
>
> Hi Qingshuang Di,
>
> I think you did everything right ... and some unexpected side
> effect occurred while setting the keys:
>
> \pgfplotsset{
> every mark/.append style=....
> }
>
> results in a NEW style /pgfplots/every mark. This style does not
> exist, and it is never queried... this is not really a bug, more a
> usability issue: the actual key in question is called
> /tikz/every mark . Writing
>
> \pgfplotsset{
> /tikz/every mark/.append style=....
> }
>
> works. Alternatively, you can use
>
> \addplot [mark=square][densely dashed,every mark/.append
> style={solid},blue,samples=10,domain=0.2:6]
>
> which has the same effect (but only local to one plot).
>
> Best regards
>
> Christian
>
> Am 17.04.2012 03:09, schrieb qingshuang di:
> >
> > DearDr. Christian Feuersanger,
> >
> > Thanks for your attention!
> >
> > I have a problem about set mark style as solid line in pgfplots.
> I have made some tests
> >
> > following the mannual, but neither worked. Can you take a look
> my tex file for help?
> >
> > Thanks!
> >
> > Best regards,
> >
> > Qingshuang Di
> >
>
------------------------------------------------------------------------------
For Developers, A Lot Can Happen In A Second.
Boundary is the first to Know...and Tell You.
Monitor Your Applications in Ultra-Fine Resolution. Try it FREE!
http://p.sf.net/sfu/Boundary-d2dvs2
_______________________________________________
Pgfplots-features mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/pgfplots-features