@@ -1045,6 +1045,82 @@ subdirectory, but :file:`galleries/users_explain/artists` has a mix of
1045
1045
any ``*.rst `` files to a ``:toctree: ``, either in the ``README.txt `` or in a
1046
1046
manual ``index.rst ``.
1047
1047
1048
+
1049
+ .. _writing-user-guide :
1050
+
1051
+ Write user guide documentation
1052
+ ==============================
1053
+
1054
+ The pages in the :ref: `users-guide-index ` are a mix of :ref: `ReST <writing-rest-pages >`
1055
+ and :ref: `sphinx gallery <writing-examples-and-tutorials >` pages and should follow the
1056
+ respective formatting conventions. The goal of the user guide is to explain how
1057
+ Matplotlib works to someone who is unfamiliar with the library. To maintain the
1058
+ consistency and cohesiveness of the user guide, documentation that is contributed to
1059
+ this section should conform to the following guidelines:
1060
+
1061
+ Purpose: Explain how Matplotlib works
1062
+ -------------------------------------
1063
+
1064
+ The aim of the user guide is to teach the concepts on which the Matplotlib API is
1065
+ developed so that users can understand how to fit the individual components of the
1066
+ library together. Therefore, content should be concept oriented rather than focused on
1067
+ specific tasks, e.g. *What is a `Line2D` artist? * rather than *How do I make a yellow
1068
+ squiggly line? *
1069
+
1070
+
1071
+ Scope: Matplotlib objects and modules
1072
+ -------------------------------------
1073
+
1074
+ Many concepts in Matplotlib assume a grounding in visualization, statistics, and
1075
+ other topics to understand how they work. These concepts should be
1076
+ contextualized using common terminilogy, but the focus should not stray from the
1077
+ Matplotlib topic, e.g. *`Line2D` objects take as input either pairwise coordinates
1078
+ (x,y) or y with an implicit x and assume that the input data is continuous. *
1079
+ Here pairwise and continuous are not defined because they are assumed to be
1080
+ known by the audience, but are used to explain what data ``Line2D `` accepts.
1081
+
1082
+
1083
+ Audience: new users
1084
+ -------------------
1085
+
1086
+ The audience for this guide are readers who are getting introduced to using Matplotlib
1087
+ through this guide; therefore, content should be written with the assumption that the
1088
+ reader does not yet know what Matplotlib calls a given visualization task nor
1089
+ how any task is accomplished in Matplotlib. For example, each document should first
1090
+ introduce or define the object/module/concept that it is discussing and why it is
1091
+ important for the reader. e.g. *The ``Line2D`` class is an abstraction of a line and
1092
+ the ``LineCollection`` class is an abstraction of a set of lines. ``Line2D`` and
1093
+ ``LineCollection`` objects manage the properties and behavior of almost every line in
1094
+ an image. This means that one way to modify a line is to call methods on its underlying
1095
+ object. *
1096
+
1097
+
1098
+ Teaching style: Chunking
1099
+ ------------------------
1100
+
1101
+ The material is introduced in small, usually one change or task at a time, chunks to
1102
+ keep focus on the specific line of code enabling the given task. The aim is that by
1103
+ reducing cognitive load, it will be easier for users to learn what each specific object
1104
+ does and how it behaves. The goal is that gaining a conceptual understanding of
1105
+ Matplotlib's API will make it easier for a user to navigate the rest of the
1106
+ documentation.
1107
+
1108
+ For example, here the line object is introduced, then there is
1109
+ one example of using a method on the object, then there is a link out to further
1110
+ functionality::
1111
+
1112
+ For example, here the ``plot`` method returns a line object ``ln``::
1113
+
1114
+ ln, _ = plt.plot([1,2,3])
1115
+
1116
+ One of the properties of a line is its color. It can be modified using the
1117
+ ``set_color`` method of ``Line2D``::
1118
+
1119
+ ln.set_color('orange')
1120
+
1121
+ For a full list of methods see `~.Line2D`
1122
+
1123
+
1048
1124
Miscellaneous
1049
1125
=============
1050
1126
0 commit comments