Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in
  • CSTools CSTools
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 28
    • Issues 28
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 2
    • Merge requests 2
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Metrics
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • External
  • CSToolsCSTools
  • Merge requests
  • !215

Add new function CST_Bind()

  • Review changes

  • Download
  • Patches
  • Plain diff
Merged vagudets requested to merge dev-CST_abind into master Nov 04, 2024
  • Overview 14
  • Commits 9
  • Pipelines 9
  • Changes 11

Hi @tkariyat

I'm opening this MR for a new function I have developed, CST_Bind(). Its purpose is to bind two s2dv_cube objects together along a specified dimension.

It is basically a wrapper of abind::abind(). The function has two levels:

  1. Bind(): designed to work with arrays with named dimensions. It binds the arrays along the dimension specified in along and preserves the dimnames. (abind::abind() does not accept dimension names and it does not preserve the dimension names in the array).
  2. CST_Bind(): designed to work with s2dv_cube objects. It binds the arrays in $data using Bind() and it also manipulates the $dims, $coords and $attrs to match $data.

For example, if a user binds two s2dv_cubes along the time dimension, the dates in $attrs$Dates will be bound together as well.

The function is not finished yet, I still need to polish some details. I will let you know when it's done so you can review it and test it.

Thank you,

Victòria

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: dev-CST_abind