@@ -256,6 +256,10 @@ macro_rules! overloaded_binary_func {
256
256
///# Return Values
257
257
///
258
258
/// An Array with results of the binary operation.
259
+ ///
260
+ ///# Note
261
+ ///
262
+ /// The trait `Convertable` essentially translates to a scalar native type on rust or Array.
259
263
pub fn $fn_name<T , U > ( arg1: & T , arg2: & U , batch: bool ) -> Array where T : Convertable , U : Convertable {
260
264
let lhs = arg1. convert( ) ;
261
265
let rhs = arg2. convert( ) ;
@@ -294,6 +298,24 @@ overloaded_binary_func!("Create complex array from two Arrays", cplx2, cplx2_hel
294
298
overloaded_binary_func ! ( "Compute root" , root, root_helper, af_root) ;
295
299
overloaded_binary_func ! ( "Computer power" , pow, pow_helper, af_pow) ;
296
300
301
+ /// Clamp the values of Array
302
+ ///
303
+ /// # Parameters
304
+ ///
305
+ /// - `arg1`is an argument that implements an internal trait `Convertable`.
306
+ /// - `arg2`is an argument that implements an internal trait `Convertable`.
307
+ /// - `batch` is an boolean that indicates if the current operation is an batch operation.
308
+ ///
309
+ /// Both parameters `arg1` and `arg2` can be either an Array or a value of rust integral
310
+ /// type.
311
+ ///
312
+ /// # Return Values
313
+ ///
314
+ /// An Array with results of the binary operation.
315
+ ///
316
+ /// # Note
317
+ ///
318
+ /// The trait `Convertable` essentially translates to a scalar native type on rust or Array.
297
319
pub fn clamp < T , U > ( input : & Array , arg1 : & T , arg2 : & U , batch : bool ) -> Array
298
320
where T : Convertable , U : Convertable
299
321
{
0 commit comments