def METHOD_NAME(filename, args):
    """
    Read a table and print to the standard output.
    Parameters
    ----------
    filename : str
        The path to a FITS file.
    """
    if args.info and args.stats:
        warnings.warn("--info and --stats cannot be used together", AstropyUserWarning)
    if any((args.max_lines, args.max_width, args.hide_unit, args.show_dtype)) and (
        args.info or args.stats
    ):
        warnings.warn(
            "print parameters are ignored if --info or --stats is used",
            AstropyUserWarning,
        )
    # these parameters are passed to Table.read if they are specified in the
    # command-line
    read_kwargs = ("hdu", "format", "table_id", "delimiter")
    kwargs = {k: v for k, v in vars(args).items() if k in read_kwargs and v is not None}
    try:
        table = Table.read(filename, **kwargs)
        if args.info:
            table.info("attributes")
        elif args.stats:
            table.info("stats")
        else:
            formatter = table.more if args.more else table.pprint
            formatter(
                max_lines=args.max_lines,
                max_width=args.max_width,
                show_unit=(False if args.hide_unit else None),
                show_dtype=(True if args.show_dtype else None),
            )
    except OSError as e:
        log.error(str(e))