Skip to content

Commit f937101

Browse files
committed
DOC: Clarify data= performance per review feedback
1 parent 68a7d56 commit f937101

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

docs/user-guide/arrays.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ module documentation.
3131
.. _user-guide-array:
3232

3333
Initializing with Data
34-
---------------------
34+
----------------------
3535
Pass existing data during array creation for better performance:
3636

3737
.. code-block:: python
@@ -42,16 +42,16 @@ Pass existing data during array creation for better performance:
4242
data = np.random.rand(1000, 1000)
4343
arr = zarr.create_array("data.zarr", shape=data.shape, data=data)
4444
45-
This avoids a separate write step and is more efficient than:
45+
This provides a more concise syntax compared to separate assignment:
4646

4747
.. code-block:: python
4848
49-
# Less efficient approach
49+
# Equivalent but verbose
5050
arr = zarr.create_array("data.zarr", shape=(1000, 1000))
5151
arr[:] = data
5252
5353
.. note::
54-
For cloud stores like S3, use ``data=`` with async writes for best performance.
54+
Both methods leverage async writes when using async-compatible stores like S3.
5555

5656
Reading and writing data
5757
------------------------

0 commit comments

Comments
 (0)