MannLabs / scPortrait

https://mannlabs.github.io/scPortrait/
Apache License 2.0
35 stars 1 forks source link

Enhance docstrings and add examples #25

Open namsaraeva opened 5 months ago

namsaraeva commented 5 months ago

We should check all docstring so that they match in the format. Add examples where needed.

namsaraeva commented 5 months ago
def function_with_pep484_type_annotations(param1: int, param2: str) -> bool:
    """Example function with PEP 484 type annotations.
    Args:
        param1: The first parameter.
        param2: The second parameter.
    Returns:
        The return value. True for success, False otherwise.
    """

I prefer this format over our current. What do you think @sophiamaedler?

Zethson commented 5 months ago

@namsaraeva is suggesting Google docstring format instead of numpy. I can happily switch to whatever when switching to the scverse template.

sophiamaedler commented 5 months ago

I'm fine with either. What's the preferred standard in scverse packages at the moment?

Would be good if we could implement some sort of check when adding new commits after switching to make sure that all doc strings are in the chosen format. We had some mismatched formats in the past that I went through and homogenized.

Zethson commented 5 months ago

It's numpy by default but many use Google (e.g. me). It's more or less a 50/50 split.

Would be good if we could implement some sort of check when adding new commits after switching to make sure that all doc strings are in the chosen format. We had some mismatched formats in the past that I went through and homogenized.

No worries, I got you :)

sophiamaedler commented 5 months ago

Then let's go with Google :-)

Let me know if you need help with something.

sophiamaedler commented 4 months ago

this should be addressed as part of #43