@Override
    public void init(String attributeName, Attribute.Type attributeType) {

        if (attributeName == null) {
            throw new SiddhiAppCreationException("Min incremental attribute aggregation cannot be executed " +
                    "when no parameters are given");
        }

        if (attributeType.equals(Attribute.Type.INT) || attributeType.equals(Attribute.Type.LONG) ||
                attributeType.equals(Attribute.Type.DOUBLE) || attributeType.equals(Attribute.Type.FLOAT)) {
            this.baseAttributes = new Attribute[]{new Attribute("AGG_MIN_".concat(attributeName), attributeType)};
            this.baseAttributesInitialValues = new Expression[]{Expression.variable(attributeName)};
            this.returnType = attributeType;
        } else {
            throw new SiddhiAppRuntimeException(
                    "Min aggregation cannot be executed on attribute type " + attributeType.toString());
        }
    }
{@link IncrementalAttributeAggregator} to calculate minimum value based on an event attribute.
modules/siddhi-core/src/main/java/io/siddhi/core/query/selector/attribute/aggregator/incremental/MinIncrementalAttributeAggregator.java