Skip to content

Commit d018acf

Browse files
author
Joao Felipe Rocha
committed
Linted test_datatypes
1 parent 88aaf07 commit d018acf

File tree

1 file changed

+16
-12
lines changed

1 file changed

+16
-12
lines changed

Python/test/test_datatypes.py

Lines changed: 16 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -279,18 +279,22 @@ def test_phate_anndata():
279279
# Create AnnData object
280280
adata = anndata.AnnData(
281281
X=data,
282-
obs=pd.DataFrame(
283-
{"cell_type": [f"type_{i%3}" for i in range(data.shape[0])]},
284-
index=[f"cell_{i}" for i in range(data.shape[0])],
285-
)
286-
if PANDAS_AVAILABLE
287-
else None,
288-
var=pd.DataFrame(
289-
{"gene_name": [f"gene_{i}" for i in range(data.shape[1])]},
290-
index=[f"gene_{i}" for i in range(data.shape[1])],
291-
)
292-
if PANDAS_AVAILABLE
293-
else None,
282+
obs=(
283+
pd.DataFrame(
284+
{"cell_type": [f"type_{i%3}" for i in range(data.shape[0])]},
285+
index=[f"cell_{i}" for i in range(data.shape[0])],
286+
)
287+
if PANDAS_AVAILABLE
288+
else None
289+
),
290+
var=(
291+
pd.DataFrame(
292+
{"gene_name": [f"gene_{i}" for i in range(data.shape[1])]},
293+
index=[f"gene_{i}" for i in range(data.shape[1])],
294+
)
295+
if PANDAS_AVAILABLE
296+
else None
297+
),
294298
)
295299

296300
print(f"Input type: {type(adata)}")

0 commit comments

Comments
 (0)