16 replaced http://stackoverflow.com/ with https://stackoverflow.com/
source | link

The following is a universal solution which extracts RGB color values assigned to the Line primitives of a plot generated by built-in plotting functions of Mathematica 10:

Cases[fplot, {___, c_Directive, __Line} :> 
   ColorConvert[c, RGBColor], Infinity] // InputForm
{RGBColor[0.368417, 0.506779, 0.709798, 1.], RGBColor[0.880722, 0.611041, 0.142051, 1.], 
 RGBColor[0.560181, 0.691569, 0.194885, 1.], RGBColor[0.922526, 0.385626, 0.209179, 1.]}

The above pattern is found by inspection of internal structure of Graphics objects produced by such functions as Plot, ListLinePlot, ParametricPlot, ContourPlot etc. of Mathematica 10.4.1. It is tested with plots generated by all listed functions and works quite reliably. If you encounter a case when it fails, please let me know.

For previous Mathematica versions more involved approach based on the colorQ function of Mr.Wizard is necessary. For example, for version 8.0.4 the following should be sufficiently general (but in many situations it will lose Opacity specification):

colorQ = Quiet@Check[Blend@{#, Red}; True, False] &;
Cases[fplot, {Longest[___], c_?colorQ, ___, __Line} :> ColorConvert[
   If[Head[c] =!= Directive, c, Last@Cases[c, _?colorQ, Infinity]]
   , RGBColor], Infinity]
{RGBColor[0.2472, 0.24, 0.6], RGBColor[0.6, 0.24, 0.442893], 
 RGBColor[0.6, 0.547014, 0.24], RGBColor[0.24, 0.6, 0.33692]}

This solution should work the same way with versions 9 and 10. The problem with Opacity is difficult to avoid because in version 8 ColorConvert cannot work with Directive.


For inspection of the structure of Graphics I recommend my shortInputForm function:

screenshot

An advanced description of the Mathematica graphical programming language can be found in these threads:


If you wish to find the default colors used by the built-in plotting functions, you should consult with the following threads:

The following is a universal solution which extracts RGB color values assigned to the Line primitives of a plot generated by built-in plotting functions of Mathematica 10:

Cases[fplot, {___, c_Directive, __Line} :> 
   ColorConvert[c, RGBColor], Infinity] // InputForm
{RGBColor[0.368417, 0.506779, 0.709798, 1.], RGBColor[0.880722, 0.611041, 0.142051, 1.], 
 RGBColor[0.560181, 0.691569, 0.194885, 1.], RGBColor[0.922526, 0.385626, 0.209179, 1.]}

The above pattern is found by inspection of internal structure of Graphics objects produced by such functions as Plot, ListLinePlot, ParametricPlot, ContourPlot etc. of Mathematica 10.4.1. It is tested with plots generated by all listed functions and works quite reliably. If you encounter a case when it fails, please let me know.

For previous Mathematica versions more involved approach based on the colorQ function of Mr.Wizard is necessary. For example, for version 8.0.4 the following should be sufficiently general (but in many situations it will lose Opacity specification):

colorQ = Quiet@Check[Blend@{#, Red}; True, False] &;
Cases[fplot, {Longest[___], c_?colorQ, ___, __Line} :> ColorConvert[
   If[Head[c] =!= Directive, c, Last@Cases[c, _?colorQ, Infinity]]
   , RGBColor], Infinity]
{RGBColor[0.2472, 0.24, 0.6], RGBColor[0.6, 0.24, 0.442893], 
 RGBColor[0.6, 0.547014, 0.24], RGBColor[0.24, 0.6, 0.33692]}

This solution should work the same way with versions 9 and 10. The problem with Opacity is difficult to avoid because in version 8 ColorConvert cannot work with Directive.


For inspection of the structure of Graphics I recommend my shortInputForm function:

screenshot

An advanced description of the Mathematica graphical programming language can be found in these threads:


If you wish to find the default colors used by the built-in plotting functions, you should consult with the following threads:

The following is a universal solution which extracts RGB color values assigned to the Line primitives of a plot generated by built-in plotting functions of Mathematica 10:

Cases[fplot, {___, c_Directive, __Line} :> 
   ColorConvert[c, RGBColor], Infinity] // InputForm
{RGBColor[0.368417, 0.506779, 0.709798, 1.], RGBColor[0.880722, 0.611041, 0.142051, 1.], 
 RGBColor[0.560181, 0.691569, 0.194885, 1.], RGBColor[0.922526, 0.385626, 0.209179, 1.]}

The above pattern is found by inspection of internal structure of Graphics objects produced by such functions as Plot, ListLinePlot, ParametricPlot, ContourPlot etc. of Mathematica 10.4.1. It is tested with plots generated by all listed functions and works quite reliably. If you encounter a case when it fails, please let me know.

For previous Mathematica versions more involved approach based on the colorQ function of Mr.Wizard is necessary. For example, for version 8.0.4 the following should be sufficiently general (but in many situations it will lose Opacity specification):

colorQ = Quiet@Check[Blend@{#, Red}; True, False] &;
Cases[fplot, {Longest[___], c_?colorQ, ___, __Line} :> ColorConvert[
   If[Head[c] =!= Directive, c, Last@Cases[c, _?colorQ, Infinity]]
   , RGBColor], Infinity]
{RGBColor[0.2472, 0.24, 0.6], RGBColor[0.6, 0.24, 0.442893], 
 RGBColor[0.6, 0.547014, 0.24], RGBColor[0.24, 0.6, 0.33692]}

This solution should work the same way with versions 9 and 10. The problem with Opacity is difficult to avoid because in version 8 ColorConvert cannot work with Directive.


For inspection of the structure of Graphics I recommend my shortInputForm function:

screenshot

An advanced description of the Mathematica graphical programming language can be found in these threads:


If you wish to find the default colors used by the built-in plotting functions, you should consult with the following threads:

15 replaced http://mathematica.stackexchange.com/ with https://mathematica.stackexchange.com/
source | link

The following is a universal solution which extracts RGB color values assigned to the Line primitives of a plot generated by built-in plotting functions of Mathematica 10:

Cases[fplot, {___, c_Directive, __Line} :> 
   ColorConvert[c, RGBColor], Infinity] // InputForm
{RGBColor[0.368417, 0.506779, 0.709798, 1.], RGBColor[0.880722, 0.611041, 0.142051, 1.], 
 RGBColor[0.560181, 0.691569, 0.194885, 1.], RGBColor[0.922526, 0.385626, 0.209179, 1.]}

The above pattern is found by inspection of internal structure of Graphics objects produced by such functions as Plot, ListLinePlot, ParametricPlot, ContourPlot etc. of Mathematica 10.4.1. It is tested with plots generated by all listed functions and works quite reliably. If you encounter a case when it fails, please let me know.

For previous Mathematica versions more involved approach based on the colorQcolorQ function of Mr.WizardMr.Wizard is necessary. For example, for version 8.0.4 the following should be sufficiently general (but in many situations it will lose Opacity specification):

colorQ = Quiet@Check[Blend@{#, Red}; True, False] &;
Cases[fplot, {Longest[___], c_?colorQ, ___, __Line} :> ColorConvert[
   If[Head[c] =!= Directive, c, Last@Cases[c, _?colorQ, Infinity]]
   , RGBColor], Infinity]
{RGBColor[0.2472, 0.24, 0.6], RGBColor[0.6, 0.24, 0.442893], 
 RGBColor[0.6, 0.547014, 0.24], RGBColor[0.24, 0.6, 0.33692]}

This solution should work the same way with versions 9 and 10. The problem with Opacity is difficult to avoid because in version 8 ColorConvert cannot work with Directive.


For inspection of the structure of Graphics I recommend my shortInputFormshortInputForm function:

screenshot

An advanced description of the Mathematica graphical programming language can be found in these threads:


If you wish to find the default colors used by the built-in plotting functions, you should consult with the following threads:

The following is a universal solution which extracts RGB color values assigned to the Line primitives of a plot generated by built-in plotting functions of Mathematica 10:

Cases[fplot, {___, c_Directive, __Line} :> 
   ColorConvert[c, RGBColor], Infinity] // InputForm
{RGBColor[0.368417, 0.506779, 0.709798, 1.], RGBColor[0.880722, 0.611041, 0.142051, 1.], 
 RGBColor[0.560181, 0.691569, 0.194885, 1.], RGBColor[0.922526, 0.385626, 0.209179, 1.]}

The above pattern is found by inspection of internal structure of Graphics objects produced by such functions as Plot, ListLinePlot, ParametricPlot, ContourPlot etc. of Mathematica 10.4.1. It is tested with plots generated by all listed functions and works quite reliably. If you encounter a case when it fails, please let me know.

For previous Mathematica versions more involved approach based on the colorQ function of Mr.Wizard is necessary. For example, for version 8.0.4 the following should be sufficiently general (but in many situations it will lose Opacity specification):

colorQ = Quiet@Check[Blend@{#, Red}; True, False] &;
Cases[fplot, {Longest[___], c_?colorQ, ___, __Line} :> ColorConvert[
   If[Head[c] =!= Directive, c, Last@Cases[c, _?colorQ, Infinity]]
   , RGBColor], Infinity]
{RGBColor[0.2472, 0.24, 0.6], RGBColor[0.6, 0.24, 0.442893], 
 RGBColor[0.6, 0.547014, 0.24], RGBColor[0.24, 0.6, 0.33692]}

This solution should work the same way with versions 9 and 10. The problem with Opacity is difficult to avoid because in version 8 ColorConvert cannot work with Directive.


For inspection of the structure of Graphics I recommend my shortInputForm function:

screenshot

An advanced description of the Mathematica graphical programming language can be found in these threads:


If you wish to find the default colors used by the built-in plotting functions, you should consult with the following threads:

The following is a universal solution which extracts RGB color values assigned to the Line primitives of a plot generated by built-in plotting functions of Mathematica 10:

Cases[fplot, {___, c_Directive, __Line} :> 
   ColorConvert[c, RGBColor], Infinity] // InputForm
{RGBColor[0.368417, 0.506779, 0.709798, 1.], RGBColor[0.880722, 0.611041, 0.142051, 1.], 
 RGBColor[0.560181, 0.691569, 0.194885, 1.], RGBColor[0.922526, 0.385626, 0.209179, 1.]}

The above pattern is found by inspection of internal structure of Graphics objects produced by such functions as Plot, ListLinePlot, ParametricPlot, ContourPlot etc. of Mathematica 10.4.1. It is tested with plots generated by all listed functions and works quite reliably. If you encounter a case when it fails, please let me know.

For previous Mathematica versions more involved approach based on the colorQ function of Mr.Wizard is necessary. For example, for version 8.0.4 the following should be sufficiently general (but in many situations it will lose Opacity specification):

colorQ = Quiet@Check[Blend@{#, Red}; True, False] &;
Cases[fplot, {Longest[___], c_?colorQ, ___, __Line} :> ColorConvert[
   If[Head[c] =!= Directive, c, Last@Cases[c, _?colorQ, Infinity]]
   , RGBColor], Infinity]
{RGBColor[0.2472, 0.24, 0.6], RGBColor[0.6, 0.24, 0.442893], 
 RGBColor[0.6, 0.547014, 0.24], RGBColor[0.24, 0.6, 0.33692]}

This solution should work the same way with versions 9 and 10. The problem with Opacity is difficult to avoid because in version 8 ColorConvert cannot work with Directive.


For inspection of the structure of Graphics I recommend my shortInputForm function:

screenshot

An advanced description of the Mathematica graphical programming language can be found in these threads:


If you wish to find the default colors used by the built-in plotting functions, you should consult with the following threads:

14 deleted 10 characters in body
source | link

The following is a universal solution which extracts RGB color values assigned to the Line primitives of a plot generated by built-in plotting functions of Mathematica 10:

Cases[fplot, {___, c_Directive, __Line} :> 
   ColorConvert[c, RGBColor], Infinity] // InputForm
{RGBColor[0.368417, 0.506779, 0.709798, 1.], RGBColor[0.880722, 0.611041, 0.142051, 1.], 
 RGBColor[0.560181, 0.691569, 0.194885, 1.], RGBColor[0.922526, 0.385626, 0.209179, 1.]}

The above pattern is found by inspection of internal structure of Graphics objects produced by such functions as Plot, ListLinePlot, ParametricPlot, ContourPlot etc. of Mathematica 10.4.1. It is tested with plots generated by all listed functions and works quite reliably. If you encounter a case when it fails, please let me know.

For previous Mathematica versions more involved approach based on the colorQ function of Mr.Wizard is necessary. For example, for version 8.0.4 the following should be sufficiently general (but in many situations it will lose Opacity specification):

colorQ = Quiet@Check[Blend@{#, Red}; True, False] &;
Cases[fplot, {Longest[___], c_?colorQ, ___, __Line} :> ColorConvert[
   If[Head[c] =!= Directive, c, Last@Cases[c, _?colorQ, Infinity]]
   , RGBColor], Infinity]
{RGBColor[0.2472, 0.24, 0.6], RGBColor[0.6, 0.24, 0.442893], 
 RGBColor[0.6, 0.547014, 0.24], RGBColor[0.24, 0.6, 0.33692]}

This solution should work the same way with versions 9 and 10. The problem with Opacity is difficult to avoid because in version 8 ColorConvert cannot work with Directive.


For inspection of the low-level structure of Graphics I recommend my shortInputForm function:

screenshot

An advanced description of the Mathematica graphical programming language can be found in these threads:


If you wish to find the default colors used by the built-in plotting functions, you should consult with the following threads:

The following is a universal solution which extracts RGB color values assigned to the Line primitives of a plot generated by built-in plotting functions of Mathematica 10:

Cases[fplot, {___, c_Directive, __Line} :> 
   ColorConvert[c, RGBColor], Infinity] // InputForm
{RGBColor[0.368417, 0.506779, 0.709798, 1.], RGBColor[0.880722, 0.611041, 0.142051, 1.], 
 RGBColor[0.560181, 0.691569, 0.194885, 1.], RGBColor[0.922526, 0.385626, 0.209179, 1.]}

The above pattern is found by inspection of internal structure of Graphics objects produced by such functions as Plot, ListLinePlot, ParametricPlot, ContourPlot etc. of Mathematica 10.4.1. It is tested with plots generated by all listed functions and works quite reliably. If you encounter a case when it fails, please let me know.

For previous Mathematica versions more involved approach based on the colorQ function of Mr.Wizard is necessary. For example, for version 8.0.4 the following should be sufficiently general (but in many situations it will lose Opacity specification):

colorQ = Quiet@Check[Blend@{#, Red}; True, False] &;
Cases[fplot, {Longest[___], c_?colorQ, ___, __Line} :> ColorConvert[
   If[Head[c] =!= Directive, c, Last@Cases[c, _?colorQ, Infinity]]
   , RGBColor], Infinity]
{RGBColor[0.2472, 0.24, 0.6], RGBColor[0.6, 0.24, 0.442893], 
 RGBColor[0.6, 0.547014, 0.24], RGBColor[0.24, 0.6, 0.33692]}

This solution should work the same way with versions 9 and 10. The problem with Opacity is difficult to avoid because in version 8 ColorConvert cannot work with Directive.


For inspection of the low-level structure of Graphics I recommend my shortInputForm function:

screenshot

An advanced description of the Mathematica graphical programming language can be found in these threads:


If you wish to find the default colors used by the built-in plotting functions, you should consult with the following threads:

The following is a universal solution which extracts RGB color values assigned to the Line primitives of a plot generated by built-in plotting functions of Mathematica 10:

Cases[fplot, {___, c_Directive, __Line} :> 
   ColorConvert[c, RGBColor], Infinity] // InputForm
{RGBColor[0.368417, 0.506779, 0.709798, 1.], RGBColor[0.880722, 0.611041, 0.142051, 1.], 
 RGBColor[0.560181, 0.691569, 0.194885, 1.], RGBColor[0.922526, 0.385626, 0.209179, 1.]}

The above pattern is found by inspection of internal structure of Graphics objects produced by such functions as Plot, ListLinePlot, ParametricPlot, ContourPlot etc. of Mathematica 10.4.1. It is tested with plots generated by all listed functions and works quite reliably. If you encounter a case when it fails, please let me know.

For previous Mathematica versions more involved approach based on the colorQ function of Mr.Wizard is necessary. For example, for version 8.0.4 the following should be sufficiently general (but in many situations it will lose Opacity specification):

colorQ = Quiet@Check[Blend@{#, Red}; True, False] &;
Cases[fplot, {Longest[___], c_?colorQ, ___, __Line} :> ColorConvert[
   If[Head[c] =!= Directive, c, Last@Cases[c, _?colorQ, Infinity]]
   , RGBColor], Infinity]
{RGBColor[0.2472, 0.24, 0.6], RGBColor[0.6, 0.24, 0.442893], 
 RGBColor[0.6, 0.547014, 0.24], RGBColor[0.24, 0.6, 0.33692]}

This solution should work the same way with versions 9 and 10. The problem with Opacity is difficult to avoid because in version 8 ColorConvert cannot work with Directive.


For inspection of the structure of Graphics I recommend my shortInputForm function:

screenshot

An advanced description of the Mathematica graphical programming language can be found in these threads:


If you wish to find the default colors used by the built-in plotting functions, you should consult with the following threads:

13 added 266 characters in body
source | link
12 deleted 5 characters in body
source | link
11 added 116 characters in body
source | link
10 added 74 characters in body
source | link
9 added 604 characters in body
source | link
8 added 119 characters in body
source | link
7 added 119 characters in body
source | link
6 added 78 characters in body
source | link
5 deleted 5 characters in body
source | link
4 added 63 characters in body
source | link
3 deleted 16 characters in body
source | link
2 added 291 characters in body
source | link
1
source | link