Closed jianyangli closed 1 year ago
Merging #367 (74d8edc) into main (462f453) will increase coverage by
0.35%
. The diff coverage is100.00%
.
@@ Coverage Diff @@
## main #367 +/- ##
==========================================
+ Coverage 75.65% 76.01% +0.35%
==========================================
Files 78 78
Lines 6795 6895 +100
==========================================
+ Hits 5141 5241 +100
Misses 1654 1654
Impacted Files | Coverage Δ | |
---|---|---|
sbpy/data/core.py | 100.00% <100.00%> (ø) |
|
sbpy/data/tests/test_dataclass.py | 98.84% <100.00%> (+0.30%) |
:arrow_up: |
@mkelley OK this one is ready for review, too. Thanks.
That failing test is something that should be marked as a remote test, and I'll have a fix in #374
OK, should I go ahead with merge, or wait for the fix first?
Go ahead.
This PR responds to issue #203 to provide a mechanism to combine
DataClass
objects. New methods implemented include:.add_row()
.add_column()
.join()
These methods allow for the same flexibilities provided by other
DataClass
methods, such as column name alias, expanding table with a newDataClass
orastropy.table.Table
object, new row, or new column with different shapes from the original table.The implementation tries to make use of the existing functionalities from
astropy.table.Table
andDataClass
as much as possible.join
function usesastropy.table.vstack
.add_row
usesDataClass.from_rows
andjoin
.add_column
usesDataClass.apply
.