# This file was auto generated by Styx.
# Do not edit this file directly.

import typing
import pathlib
from styxdefs import *
import dataclasses

QUICK_ALPHA_VALS_PY_METADATA = Metadata(
    id="ed5c29d1849d5d08aef7cc64a2336c02bab2e572.boutiques",
    name="quick.alpha.vals.py",
    package="afni",
    container_image_tag="afni/afni_make_build:AFNI_24.2.06",
)


class QuickAlphaValsPyOutputs(typing.NamedTuple):
    """
    Output object returned when calling `quick_alpha_vals_py(...)`.
    """
    root: OutputPathType
    """Output root folder. This is the root folder for all outputs."""
    alpha_table: OutputPathType
    """Generated alpha table file"""


def quick_alpha_vals_py(
    max_file: InputPathType,
    niter: int | None = None,
    runner: Runner | None = None,
) -> QuickAlphaValsPyOutputs:
    """
    Generate an alpha table from slow_surf_clustsim.py results.
    
    Author: AFNI Team
    
    URL:
    https://afni.nimh.nih.gov/pub/dist/doc/program_help/quick.alpha.vals.py.html
    
    Args:
        max_file: File containing maximum z values.
        niter: Number of iterations that should be in the z file.
        runner: Command runner.
    Returns:
        NamedTuple of outputs (described in `QuickAlphaValsPyOutputs`).
    """
    runner = runner or get_global_runner()
    execution = runner.start_execution(QUICK_ALPHA_VALS_PY_METADATA)
    cargs = []
    cargs.append("quick.alpha.vals.py")
    if niter is not None:
        cargs.extend([
            "-niter",
            str(niter)
        ])
    cargs.append(execution.input_file(max_file))
    ret = QuickAlphaValsPyOutputs(
        root=execution.output_file("."),
        alpha_table=execution.output_file("alpha_table.txt"),
    )
    execution.run(cargs)
    return ret


__all__ = [
    "QUICK_ALPHA_VALS_PY_METADATA",
    "QuickAlphaValsPyOutputs",
    "quick_alpha_vals_py",
]
