@@ -140,6 +140,46 @@ def image(self, img, title=None):
140140 _cell = _Cell (self ._r , self ._c , title , self ._cmap )
141141 safe_call (backend .get ().af_draw_image (self ._wnd , img .arr , ct .pointer (_cell )))
142142
143+ def scatter (self , X , Y , marker = MARKER .POINT , title = None ):
144+ """
145+ Renders input arrays as 2D scatter plot.
146+
147+ Paramters
148+ ---------
149+
150+ X: af.Array.
151+ A 1 dimensional array containing X co-ordinates.
152+
153+ Y: af.Array.
154+ A 1 dimensional array containing Y co-ordinates.
155+
156+ marker: af.MARKER
157+ Specifies how the points look
158+
159+ title: str.
160+ Title used for the plot.
161+ """
162+ _cell = _Cell (self ._r , self ._c , title , self ._cmap )
163+ safe_call (backend .get ().af_draw_scatter (self ._wnd , X .arr , Y .arr ,
164+ marker .value , ct .pointer (_cell )))
165+
166+ def scatter3 (self , P , marker = MARKER .POINT , title = None ):
167+ """
168+ Renders the input array as a 3D Scatter plot.
169+
170+ Paramters
171+ ---------
172+
173+ P: af.Array.
174+ A 2 dimensional array containing (X,Y,Z) co-ordinates.
175+
176+ title: str.
177+ Title used for the plot.
178+ """
179+ _cell = _Cell (self ._r , self ._c , title , self ._cmap )
180+ safe_call (backend .get ().af_draw_scatter3 (self ._wnd , P .arr ,
181+ marker .value , ct .pointer (_cell )))
182+
143183 def plot (self , X , Y , title = None ):
144184 """
145185 Display a 2D Plot.
@@ -255,6 +295,16 @@ def close(self):
255295 safe_call (backend .get ().af_is_window_closed (ct .pointer (tmp ), self ._wnd ))
256296 return tmp
257297
298+ def set_visibility (is_visible ):
299+ """
300+ A flag that shows or hides the window as requested.
301+
302+ Parameters
303+ ----------
304+ is_visible: Flag specifying the visibility of the flag.
305+ """
306+ safe_call (backend .get ().af_set_visibility (self ._wnd , is_visible ))
307+
258308 def __getitem__ (self , keys ):
259309 """
260310 Get access to a specific grid location within the window.
0 commit comments