Changeset 1779 for branches/mergetest/src/Scantable.h
- Timestamp:
- 07/29/10 19:13:46 (14 years ago)
- Location:
- branches/mergetest
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/mergetest
- Property svn:mergeinfo changed
-
branches/mergetest/src/Scantable.h
r1730 r1779 29 29 30 30 #include <coordinates/Coordinates/SpectralCoordinate.h> 31 32 #include <casa/Arrays/Vector.h> 33 #include <casa/Quanta/Quantum.h> 34 35 #include <casa/Exceptions/Error.h> 31 36 32 37 #include "Logger.h" … … 226 231 227 232 /** 233 * Flag the data in a row-based manner. (CAS-1433 Wataru Kawasaki) 234 * param[in] rows list of row numbers to be flagged 235 */ 236 void flagRow( const std::vector<casa::uInt>& rows = std::vector<casa::uInt>(), bool unflag=false); 237 238 /** 239 * Get flagRow info at the specified row. If true, the whole data 240 * at the row should be flagged. 241 */ 242 bool getFlagRow(int whichrow) const 243 { return (flagrowCol_(whichrow) > 0); } 244 245 /** 246 * Flag the data outside a specified range (in a channel-based manner). 247 * (CAS-1807 Wataru Kawasaki) 248 */ 249 void clip(const casa::Float uthres, const casa::Float dthres, bool clipoutside, bool unflag); 250 251 /** 252 * Return a list of booleans with the size of nchan for a specified row, to get info 253 * about which channel is clipped. 254 */ 255 std::vector<bool> getClipMask(int whichrow, const casa::Float uthres, const casa::Float dthres, bool clipoutside, bool unflag); 256 void srchChannelsToClip(casa::uInt whichrow, const casa::Float uthres, const casa::Float dthres, bool clipoutside, bool unflag, 257 casa::Vector<casa::uChar> flgs); 258 259 /** 228 260 * Return a list of row numbers with respect to the original table. 229 261 * @return a list of unsigned ints … … 276 308 std::vector<uint> getScanNos() const { return getNumbers(scanCol_); } 277 309 int getScan(int whichrow) const { return scanCol_(whichrow); } 310 311 //TT addition 312 std::vector<uint> getMolNos() {return getNumbers(mmolidCol_); } 278 313 279 314 /** … … 300 335 { return azCol_(whichrow); } 301 336 float getParAngle(int whichrow) const 302 { return focus().getParAngle(mfocusidCol_(whichrow)); } 337 { return focus().getParAngle(mfocusidCol_(whichrow)); } 338 int getTcalId(int whichrow) const 339 { return mtcalidCol_(whichrow); } 303 340 304 341 std::string getSourceName(int whichrow) const … … 353 390 std::vector<double> getRestFrequencies() const 354 391 { return moleculeTable_.getRestFrequencies(); } 355 392 std::vector<double> getRestFrequency(int id) const 393 { return moleculeTable_.getRestFrequency(id); } 394 395 /** 356 396 void setRestFrequencies(double rf, const std::string& name = "", 357 397 const std::string& = "Hz"); 358 void setRestFrequencies(const std::string& name); 398 **/ 399 // Modified by Takeshi Nakazato 05/09/2008 400 /*** 401 void setRestFrequencies(vector<double> rf, const vector<std::string>& name = "", 402 const std::string& = "Hz"); 403 ***/ 404 void setRestFrequencies(vector<double> rf, 405 const vector<std::string>& name = vector<std::string>(1,""), 406 const std::string& = "Hz"); 407 408 //void setRestFrequencies(const std::string& name); 409 void setRestFrequencies(const vector<std::string>& name); 359 410 360 411 void shift(int npix); … … 415 466 { focus().setParallactify(flag); } 416 467 468 /** 469 * Reshape spectrum 470 * @param[in] nmin, nmax minimum and maximum channel 471 * @param[in] irow row number 472 * 473 * 30/07/2008 Takeshi Nakazato 474 **/ 475 void reshapeSpectrum( int nmin, int nmax ) throw( casa::AipsError ); 476 void reshapeSpectrum( int nmin, int nmax, int irow ) ; 477 478 /** 479 * Change channel number under fixed bandwidth 480 * @param[in] nchan, dnu new channel number and spectral resolution 481 * @param[in] irow row number 482 * 483 * 27/08/2008 Takeshi Nakazato 484 **/ 485 void regridChannel( int nchan, double dnu ) ; 486 void regridChannel( int nchan, double dnu, int irow ) ; 487 488 417 489 private: 418 490 … … 489 561 casa::ScalarColumn<casa::Float> elCol_; 490 562 casa::ScalarColumn<casa::String> srcnCol_, fldnCol_; 491 casa::ScalarColumn<casa::uInt> scanCol_, beamCol_, ifCol_, polCol_, cycleCol_ ;563 casa::ScalarColumn<casa::uInt> scanCol_, beamCol_, ifCol_, polCol_, cycleCol_, flagrowCol_; 492 564 casa::ScalarColumn<casa::Int> rbeamCol_, srctCol_; 493 565 casa::ArrayColumn<casa::Float> specCol_, tsysCol_; … … 510 582 void initFactories(); 511 583 584 /** 585 * Add an auxiliary column to the main table and attach it to a 586 * cached column. Use for adding new columns that the original asap2 587 * tables do not have. 588 * @param[in] col reference to the cached column to be attached 589 * @param[in] colName column name in asap table 590 * @param[in] defValue default value to fill in the column 591 * 592 * 25/10/2009 Wataru Kawasaki 593 */ 594 template<class T, class T2> void attachAuxColumnDef(casa::ScalarColumn<T>&, 595 const casa::String&, 596 const T2&); 597 template<class T, class T2> void attachAuxColumnDef(casa::ArrayColumn<T>&, 598 const casa::String&, 599 const casa::Array<T2>&); 512 600 }; 513 601
Note: See TracChangeset
for help on using the changeset viewer.