-- DBMS: bigquery
CREATE TABLE `isb-cgc-bq.HTAN_versioned.imaging_level4_TNP_TMA_phase3_r4`
(
  CellID INT64 OPTIONS(description="Unique cell identifier in a specific image"),
  Hoechst1 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  A488 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  A555 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  A647 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  Hoechst2 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CD3_Rat FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CD11c FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  GranB FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  Hoechst3 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  Ki67 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  panCK FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CD45 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  Hoechst4 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CD4 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CD68 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CD8a FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  Hoechst5 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CD11b FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  FOXP3 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  PDL1_1 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  Hoechst6 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  PCNA FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  ER FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  HER2 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  Hoechst7 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CD20 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  aSMA FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  PD1 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  Hoechst8 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CD57 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  PDL1_2 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CD3d FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  Hoechst9 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CD163 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  HLA_DR FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  HLA_DPB1 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  Hoechst10 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CD15 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CD44 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  PDPN FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  X_centroid FLOAT64 OPTIONS(description="X-position of the centroid calculated as the center of mass of the cell."),
  Y_centroid FLOAT64 OPTIONS(description="Y-position of the centroid calculated as the center of mass of the cell."),
  Area INT64 OPTIONS(description="Actual number of pixels in the region, returned as a scalar."),
  MajorAxisLength FLOAT64 OPTIONS(description="Length (in pixels) of the major axis of the ellipse that has the same normalized second central moments as the region, returned as a scalar."),
  MinorAxisLength FLOAT64 OPTIONS(description="Length (in pixels) of the minor axis of the ellipse that has the same normalized second central moments as the region, returned as a scalar."),
  Eccentricity FLOAT64 OPTIONS(description="Eccentricity of the ellipse that has the same second-moments as the region, returned as a scalar. The eccentricity is the ratio of the distance between the foci of the ellipse and its major axis length. The value is between 0 and 1. (0 and 1 are degenerate cases. An ellipse whose eccentricity is 0 is actually a circle, while an ellipse whose eccentricity is 1 is a line segment.)"),
  Solidity FLOAT64 OPTIONS(description="Proportion of the pixels in the convex hull that are also in the region, returned as a scalar. Computed as Area/ConvexArea."),
  Extent FLOAT64 OPTIONS(description="Ratio of pixels in the region to pixels in the total bounding box, returned as a scalar. Computed as the Area divided by the area of the bounding box."),
  Orientation FLOAT64 OPTIONS(description="Angle between the x-axis and the major axis of the ellipse that has the same second-moments as the region, returned as a scalar. The value is in degrees, ranging from −90 degrees to 90 degrees."),
  Source_filename STRING OPTIONS(description="Name of file record was derived from"),
  Source_entityId STRING OPTIONS(description="Synapse ID of source file"),
  HTAN_Center STRING OPTIONS(description="Name of HTAN Center e.g. HTAN HTAPP"),
  HTAN_Data_File_ID STRING OPTIONS(description="Self-identifier for this data file - HTAN ID of this file HTAN ID SOP (eg HTANx_yyy_zzz)"),
  HTAN_Biospecimen_ID STRING OPTIONS(description="HTAN ID associated with a biosample based on HTAN ID SOP (eg HTANx_yyy_zzz)"),
  PolICTD FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  pERK FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  p53 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  Ecad FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  SMA FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  Vimentin FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  EGFR FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  pRB FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  p21 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CK14 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CK19 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CK17 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  LaminA_C FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  AR FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  H2ax FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  PR FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  HLAA FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker"),
  CK5 FLOAT64 OPTIONS(description="Mean intensity of pixels for specified marker")
)
OPTIONS(
  friendly_name="HTAN TNP TMA IMAGING LEVEL 4 DATA - PHASE 3 R4 VERSIONED",
  description="Data was derived in October 2023 from 176 Imaging Level 4 csv files submitted by the TNP TMA HTAN center.",
  labels=[("access", "open"), ("data_type", "cell_spatial_characterization"), ("program", "htan"), ("source", "htan-tnp-tma"), ("category", "processed_-omics_data"), ("status", "current")]
);

INSERT INTO `isb-cgc-bq.HTAN_versioned.imaging_level4_TNP_TMA_phase3_r4` (CellID, Hoechst1, A488, A555, A647, Hoechst2, CD3_Rat, CD11c, GranB, Hoechst3, Ki67, panCK, CD45, Hoechst4, CD4, CD68, CD8a, Hoechst5, CD11b, FOXP3, PDL1_1, Hoechst6, PCNA, ER, HER2, Hoechst7, CD20, aSMA, PD1, Hoechst8, CD57, PDL1_2, CD3d, Hoechst9, CD163, HLA_DR, HLA_DPB1, Hoechst10, CD15, CD44, PDPN, X_centroid, Y_centroid, Area, MajorAxisLength, MinorAxisLength, Eccentricity, Solidity, Extent, Orientation, Source_filename, Source_entityId, HTAN_Center, HTAN_Data_File_ID, HTAN_Biospecimen_ID, PolICTD, pERK, p53, Ecad, SMA, Vimentin, EGFR, pRB, p21, CK14, CK19, CK17, LaminA_C, AR, H2ax, PR, HLAA, CK5) VALUES (8717, 12546.188481675392, 828.937172774869, 245.80104712041884, 1113.3403141361257, 6851.994764397906, 1804.1151832460728, 1289.780104712042, 1652.649214659686, 6473.120418848168, 712.5497382198953, 28058.109947643978, 2298.528795811518, 8015.717277486911, 1234.0, 360.0366492146597, 1494.780104712042, 5779.539267015707, 1687.869109947644, 287.5916230366492, 2978.7120418848167, 5211.691099476439, 3068.4450261780103, 247.4869109947644, 2124.057591623037, 5208.471204188481, 3103.4450261780103, 498.6806282722513, 3042.774869109948, 2382.1256544502617, 1120.5968586387437, 681.717277486911, 2827.1623036649216, 1640.6701570680627, 4150.225130890052, 169.09947643979058, 1033.0628272251308, 1177.6230366492146, 1073.4659685863874, 201.94240837696336, 1313.7120418848167, 161.9895287958115, 824.4397905759163, 191, 18.236123842160456, 13.79322804956042, 0.6541458735121283, 0.8925233644859814, 0.7074074074074074, 0.1212013778154075, 'LSP12021-A10_LSP12021-A10-cellRingMask.csv', 'syn52043931', 'HTAN TNP - TMA', 'HTA14_10_1084', 'HTA14_10_55', nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan), (12968, 44365.63247863248, 1907.5811965811963, 480.45299145299145, 1227.7948717948718, 27018.4358974359, 3704.410256410256, 1560.008547008547, 1681.1196581196582, 23302.521367521367, 1321.3931623931624, 19116.521367521367, 2344.871794871795, 29269.06837606837, 2114.4957264957266, 579.0, 1401.3333333333333, 26275.21367521368, 2791.076923076923, 558.6153846153846, 3155.153846153846, 25792.196581196586, 7009.811965811966, 500.52991452991455, 2215.162393162393, 30667.76923076923, 3760.948717948718, 718.5897435897435, 3136.965811965812, 22792.128205128207, 1915.7521367521367, 1240.3162393162393, 3118.837606837607, 20254.60683760684, 5745.068376068376, 299.1794871794872, 1073.8119658119658, 21158.71794871795, 1745.8632478632478, 343.017094017094, 1401.948717948718, 1495.2991452991453, 956.3675213675214, 117, 16.664496579269716, 9.593483686517285, 0.8176722798104251, 0.8666666666666667, 0.609375, -1.231740758223686, 'LSP12021-A10_LSP12021-A10-cellRingMask.csv', 'syn52043931', 'HTAN TNP - TMA', 'HTA14_10_1084', 'HTA14_10_55', nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan), (22921, 14756.81981981982, 894.7747747747748, 272.5315315315315, 1088.0720720720722, 8418.117117117117, 1874.2702702702704, 587.8018018018018, 1571.5225225225224, 8155.810810810811, 864.5585585585585, 19183.45945945946, 2281.5405405405404, 10544.63063063063, 1453.7477477477478, 335.26126126126127, 1658.936936936937, 9116.405405405403, 1756.1891891891892, 298.1441441441441, 2978.4774774774774, 31880.6036036036, 5988.441441441441, 1295.1351351351352, 2879.837837837838, 11024.108108108108, 1950.036036036036, 1154.6306306306303, 3019.954954954955, 7240.306306306306, 1210.6756756756756, 909.6126126126126, 3013.009009009009, 6999.720720720721, 3145.3603603603606, 204.02702702702703, 821.5495495495495, 9765.9009009009, 1366.4324324324325, 431.1171171171171, 1689.8018018018015, 1918.4864864864865, 1224.045045045045, 111, 16.418585531838236, 9.425768554662962, 0.8187912300370285, 0.8538461538461538, 0.6098901098901099, -0.8723563132591797, 'LSP12021-A10_LSP12021-A10-cellRingMask.csv', 'syn52043931', 'HTAN TNP - TMA', 'HTA14_10_1084', 'HTA14_10_55', nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan), (26378, 10991.901408450703, 896.7887323943662, 281.66901408450707, 1066.8028169014085, 6136.359154929577, 2589.345070422535, 461.2887323943662, 1581.161971830986, 6048.154929577465, 877.2112676056338, 597.1549295774648, 2281.4647887323945, 7341.014084507042, 1404.43661971831, 316.0211267605634, 1899.2042253521129, 6679.74647887324, 2143.9647887323945, 292.0845070422535, 2959.9647887323945, 6876.267605633803, 3897.24647887324, 258.0211267605634, 2755.9718309859154, 1167.338028169014, 2180.1338028169016, 4095.091549295775, 2971.5915492957747, 4291.852112676056, 1765.0140845070423, 1214.7605633802816, 3162.859154929577, 3195.957746478873, 2946.992957746479, 184.81690140845072, 697.9154929577464, 243.93661971830983, 870.9647887323944, 177.92957746478874, 1154.6478873239437, 2223.260563380282, 1307.2957746478874, 142, 16.092981038543098, 11.444677839013966, 0.7030306066308261, 0.9161290322580644, 0.6761904761904762, 0.8515139644854831, 'LSP12021-A10_LSP12021-A10-cellRingMask.csv', 'syn52043931', 'HTAN TNP - TMA', 'HTA14_10_1084', 'HTA14_10_55', nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan), (32273, 44742.07746478873, 1938.2887323943664, 491.6619718309859, 1147.7112676056338, 24010.690140845072, 3803.654929577465, 1156.3309859154929, 1620.4788732394366, 24271.274647887323, 1433.7535211267605, 7714.12676056338, 2340.711267605634, 31224.147887323943, 2201.0140845070423, 579.8028169014085, 2074.260563380282, 26778.936619718308, 3209.830985915493, 571.5915492957746, 3072.9084507042253, 37316.26056338028, 5663.619718309859, 678.9788732394367, 2748.7464788732395, 31145.535211267605, 3379.4014084507044, 1249.9225352112676, 3111.394366197183, 25495.401408450703, 2324.1338028169016, 1735.225352112676, 3341.43661971831, 21835.908450704224, 5169.338028169014, 309.7535211267606, 1056.725352112676, 23787.00704225352, 1916.2323943661968, 482.1901408450704, 1651.3661971830986, 2171.788732394366, 1446.401408450704, 142, 16.19781448553754, 11.536861156510458, 0.7019278953301784, 0.9044585987261148, 0.6826923076923077, 0.1523020375454848, 'LSP12021-A10_LSP12021-A10-cellRingMask.csv', 'syn52043931', 'HTAN TNP - TMA', 'HTA14_10_1084', 'HTA14_10_55', nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan, nan);