问:
If-Else Statement in R with 3 conditions
I am trying to use an if-else statement to create a column in my data set. I want this if-else statement to create a column called "Surgical" in the df "option1" that displays the value of the column "Duration" subtracted by 20 ONLY IF the value in Duration is above 625, AND the factor "Single" is indicated in the column "Variability".
I have tried the following code:

```<code>option1$Surgical <- ifelse(option1$Variability == "Single", option1$Duration - 20, option1$Duration)
</code>```

Any insight into how to specify the "only if the value is greater than 625" portion is appreciated!!

Df "option 1" for reference.

dput(option1)
      structure(list(Stimulus = structure(c(36L, 37L, 38L, 39L, 40L,
      41L, 42L, 43L, 44L, 45L, 50L, 51L, 52L, 53L, 54L, 55L, 56L, 60L,
      61L, 62L, 63L, 64L, 65L, 66L, 67L, 73L, 74L, 75L, 76L, 77L, 78L,
      79L, 31L, 32L, 33L, 34L, 35L, 36L, 37L, 38L, 39L, 40L, 46L, 47L,
      48L, 49L, 50L, 51L, 52L, 53L, 57L, 58L, 59L, 60L, 61L, 62L, 63L,
      69L, 70L, 71L, 72L, 73L, 74L, 75L, 36L, 37L, 38L, 39L, 40L, 41L,
      42L, 43L, 44L, 45L, 50L, 51L, 52L, 53L, 54L, 55L, 56L, 60L, 61L,
      62L, 63L, 64L, 65L, 66L, 67L, 73L, 74L, 75L, 76L, 77L, 78L, 79L,
      31L, 32L, 33L, 34L, 35L, 36L, 37L, 38L, 39L, 40L, 46L, 47L, 48L,
      49L, 50L, 51L, 52L, 53L, 57L, 58L, 59L, 60L, 61L, 62L, 63L, 69L,
      70L, 71L, 72L, 73L, 74L, 75L, 7L, 9L, 12L, 18L, 28L, 26L, 51L,
      37L, 3L, 2L, 19L, 14L, 27L, 23L, 65L, 77L, 7L, 9L, 12L, 18L,
      28L, 26L, 51L, 37L, 3L, 2L, 19L, 14L, 27L, 23L, 65L, 77L, 5L,
      11L, 20L, 16L, 30L, 25L, 35L, 33L, 7L, 9L, 12L, 18L, 28L, 26L,
      51L, 37L, 5L, 11L, 20L, 16L, 30L, 25L, 35L, 33L, 7L, 9L, 12L,
      18L, 28L, 26L, 51L, 37L), .Label = c("t1_block2_hoed3.mp3", "t1_block2_whod3.mp3",
      "t1_block2_whod4.mp3", "t1_block2_whod5.mp3", "t1_block3_heed2.mp3",
      "t1_block3_heed5.mp3", "t1_block3_hoed1.mp3", "t1_block3_hoed2.mp3",
      "t1_block3_hoed4.mp3", "t1_block3_whod3.mp3", "t1_block4_heed5.mp3",
      "t2_block1_hoed3.mp3", "t2_block1_whod1.mp3", "t2_block1_whod2.mp3",
      "t2_block1_whod4.mp3", "t2_block2_heed3.mp3", "t2_block2_hoed5.mp3",
      "t2_block3_hoed1.mp3", "t2_block3_whod1.mp3", "t2_block4_heed2.mp3",
      "t2_block4_heed5.mp3", "t3_block1_heed1.mp3", "t3_block1_whod2.mp3",
      "t3_block1_whod5.mp3", "t3_block2_heed5.mp3", "t3_block2_hoed2.mp3",
      "t3_block2_whod5.mp3", "t3_block3_hoed1.mp3", "t3_block3_hoed4.mp3",
      "t3_block4_heed3.mp3", "t4_block1_heed1.mp3", "t4_block1_heed2.mp3",
      "t4_block1_heed3.mp3", "t4_block1_heed4.mp3", "t4_block1_heed5.mp3",
      "t4_block1_hoed1.mp3", "t4_block1_hoed2.mp3", "t4_block1_hoed3.mp3",
      "t4_block1_hoed4.mp3", "t4_block1_hoed5.mp3", "t4_block1_whod1.mp3",
      "t4_block1_whod2.mp3", "t4_block1_whod3.mp3", "t4_block1_whod4.mp3",
      "t4_block1_whod5.mp3", "t4_block2_heed1.mp3", "t4_block2_heed2.mp3",
      "t4_block2_heed4.mp3", "t4_block2_heed5.mp3", "t4_block2_hoed1.mp3",
      "t4_block2_hoed3.mp3", "t4_block2_hoed4.mp3", "t4_block2_hoed5.mp3",
      "t4_block2_whod2.mp3", "t4_block2_whod4.mp3", "t4_block2_whod5.mp3",
      "t4_block3_heed1.mp3", "t4_block3_heed4.mp3", "t4_block3_heed5.mp3",
      "t4_block3_hoed1.mp3", "t4_block3_hoed2.mp3", "t4_block3_hoed4.mp3",
      "t4_block3_hoed5.mp3", "t4_block3_whod1.mp3", "t4_block3_whod2.mp3",
      "t4_block3_whod3.mp3", "t4_block3_whod5.mp3", "t4_block4_heed1.mp3",
      "t4_block4_heed2.mp3", "t4_block4_heed3.mp3", "t4_block4_heed4.mp3",
      "t4_block4_heed5.mp3", "t4_block4_hoed1.mp3", "t4_block4_hoed2.mp3",
      "t4_block4_hoed3.mp3", "t4_block4_whod1.mp3", "t4_block4_whod2.mp3",
      "t4_block4_whod3.mp3", "t4_block4_whod5.mp3"), class = "factor"),
          Duration = c(497L, 517L, 580L, 563L, 569L, 486L, 506L, 536L,
          545L, 554L, 516L, 600L, 607L, 577L, 537L, 583L, 544L, 566L,
          567L, 616L, 652L, 564L, 517L, 612L, 564L, 632L, 662L, 565L,
          594L, 622L, 552L, 542L, 539L, 554L, 600L, 607L, 577L, 497L,
          517L, 580L, 563L, 569L, 594L, 563L, 623L, 602L, 516L, 600L,
          607L, 577L, 531L, 642L, 624L, 566L, 567L, 616L, 652L, 654L,
          576L, 556L, 608L, 632L, 662L, 565L, 497L, 517L, 580L, 563L,
          569L, 486L, 506L, 536L, 545L, 554L, 516L, 600L, 607L, 577L,
          537L, 583L, 544L, 566L, 567L, 616L, 652L, 564L, 517L, 612L,
          564L, 632L, 662L, 565L, 594L, 622L, 552L, 542L, 539L, 554L,
          600L, 607L, 577L, 497L, 517L, 580L, 563L, 569L, 594L, 563L,
          623L, 602L, 516L, 600L, 607L, 577L, 531L, 642L, 624L, 566L,
          567L, 616L, 652L, 654L, 576L, 556L, 608L, 632L, 662L, 565L,
          452L, 547L, 510L, 663L, 470L, 503L, 600L, 517L, 491L, 505L,
          641L, 581L, 520L, 485L, 517L, 622L, 452L, 547L, 510L, 663L,
          470L, 503L, 600L, 517L, 491L, 505L, 641L, 581L, 520L, 485L,
          517L, 622L, 510L, 458L, 558L, 638L, 483L, 538L, 577L, 600L,
          452L, 547L, 510L, 663L, 470L, 503L, 600L, 517L, 510L, 458L,
          558L, 638L, 483L, 538L, 577L, 600L, 452L, 547L, 510L, 663L,
          470L, 503L, 600L, 517L), F0 = c(196L, 204L, 204L, 197L, 203L,
          216L, 208L, 223L, 213L, 219L, 196L, 202L, 205L, 202L, 208L,
          205L, 206L, 197L, 202L, 195L, 200L, 201L, 210L, 202L, 208L,
          195L, 196L, 195L, 205L, 208L, 203L, 203L, 212L, 213L, 210L,
          206L, 204L, 196L, 204L, 204L, 197L, 203L, 201L, 198L, 199L,
          203L, 196L, 202L, 205L, 202L, 193L, 195L, 208L, 197L, 202L,
          195L, 200L, 201L, 195L, 205L, 202L, 195L, 196L, 195L, 196L,
          204L, 204L, 197L, 203L, 216L, 208L, 223L, 213L, 219L, 196L,
          202L, 205L, 202L, 208L, 205L, 206L, 197L, 202L, 195L, 200L,
          201L, 210L, 202L, 208L, 195L, 196L, 195L, 205L, 208L, 203L,
          203L, 212L, 213L, 210L, 206L, 204L, 196L, 204L, 204L, 197L,
          203L, 201L, 198L, 199L, 203L, 196L, 202L, 205L, 202L, 193L,
          195L, 208L, 197L, 202L, 195L, 200L, 201L, 195L, 205L, 202L,
          195L, 196L, 195L, 215L, 219L, 219L, 220L, 199L, 202L, 202L,
          204L, 224L, 231L, 238L, 240L, 217L, 212L, 210L, 208L, 215L,
          219L, 219L, 220L, 199L, 202L, 202L, 204L, 224L, 231L, 238L,
          240L, 217L, 212L, 210L, 208L, 230L, 223L, 219L, 221L, 199L,
          200L, 204L, 210L, 215L, 219L, 219L, 220L, 199L, 202L, 202L,
          204L, 230L, 223L, 219L, 221L, 199L, 200L, 204L, 210L, 215L,
          219L, 219L, 220L, 199L, 202L, 202L, 204L), F1 = c(576L, 553L,
          579L, 586L, 601L, 398L, 390L, 398L, 389L, 404L, 587L, 560L,
          562L, 553L, 393L, 397L, 382L, 553L, 592L, 556L, 571L, 387L,
          392L, 398L, 400L, 580L, 580L, 554L, 403L, 391L, 388L, 393L,
          382L, 375L, 384L, 392L, 388L, 576L, 553L, 579L, 586L, 601L,
          387L, 393L, 402L, 406L, 587L, 560L, 562L, 553L, 388L, 391L,
          412L, 553L, 592L, 556L, 571L, 410L, 404L, 401L, 420L, 580L,
          580L, 554L, 576L, 553L, 579L, 586L, 601L, 398L, 390L, 398L,
          389L, 404L, 587L, 560L, 562L, 553L, 393L, 397L, 382L, 553L,
          592L, 556L, 571L, 387L, 392L, 398L, 400L, 580L, 580L, 554L,
          403L, 391L, 388L, 393L, 382L, 375L, 384L, 392L, 388L, 576L,
          553L, 579L, 586L, 601L, 387L, 393L, 402L, 406L, 587L, 560L,
          562L, 553L, 388L, 391L, 412L, 553L, 592L, 556L, 571L, 410L,
          404L, 401L, 420L, 580L, 580L, 554L, 620L, 630L, 602L, 605L,
          571L, 573L, 560L, 553L, 434L, 417L, 306L, 319L, 414L, 419L,
          392L, 391L, 620L, 630L, 602L, 605L, 571L, 573L, 560L, 553L,
          434L, 417L, 306L, 319L, 414L, 419L, 392L, 391L, 448L, 441L,
          293L, 291L, 420L, 420L, 388L, 384L, 620L, 630L, 602L, 605L,
          571L, 573L, 560L, 553L, 448L, 441L, 293L, 291L, 420L, 420L,
          388L, 384L, 620L, 630L, 602L, 605L, 571L, 573L, 560L, 553L
          ), F2 = c(1339L, 1381L, 1381L, 1347L, 1394L, 1484L, 1521L,
          1539L, 1430L, 1454L, 1353L, 1378L, 1325L, 1357L, 1424L, 1563L,
          1578L, 1350L, 1397L, 1273L, 1319L, 1548L, 1452L, 1499L, 1515L,
          1358L, 1347L, 1248L, 1575L, 1438L, 1414L, 1548L, 3001L, 2916L,
          2948L, 2973L, 2947L, 1339L, 1381L, 1381L, 1347L, 1394L, 2943L,
          2913L, 2987L, 2940L, 1353L, 1378L, 1325L, 1357L, 3010L, 3008L,
          2972L, 1350L, 1397L, 1273L, 1319L, 2963L, 2991L, 3007L, 2989L,
          1358L, 1347L, 1248L, 1339L, 1381L, 1381L, 1347L, 1394L, 1484L,
          1521L, 1539L, 1430L, 1454L, 1353L, 1378L, 1325L, 1357L, 1424L,
          1563L, 1578L, 1350L, 1397L, 1273L, 1319L, 1548L, 1452L, 1499L,
          1515L, 1358L, 1347L, 1248L, 1575L, 1438L, 1414L, 1548L, 3001L,
          2916L, 2948L, 2973L, 2947L, 1339L, 1381L, 1381L, 1347L, 1394L,
          2943L, 2913L, 2987L, 2940L, 1353L, 1378L, 1325L, 1357L, 3010L,
          3008L, 2972L, 1350L, 1397L, 1273L, 1319L, 2963L, 2991L, 3007L,
          2989L, 1358L, 1347L, 1248L, 1247L, 1244L, 1293L, 1264L, 1348L,
          1354L, 1378L, 1381L, 1314L, 1233L, 1190L, 1208L, 1643L, 1659L,
          1452L, 1438L, 1247L, 1244L, 1293L, 1264L, 1348L, 1354L, 1378L,
          1381L, 1314L, 1233L, 1190L, 1208L, 1643L, 1659L, 1452L, 1438L,
          2837L, 2816L, 2780L, 2776L, 2684L, 2718L, 2947L, 2948L, 1247L,
          1244L, 1293L, 1264L, 1348L, 1354L, 1378L, 1381L, 2837L, 2816L,
          2780L, 2776L, 2684L, 2718L, 2947L, 2948L, 1247L, 1244L, 1293L,
          1264L, 1348L, 1354L, 1378L, 1381L), F3 = c(2831L, 2779L,
          2915L, 2875L, 2712L, 2730L, 2793L, 2779L, 2772L, 2692L, 2718L,
          2856L, 2674L, 2659L, 2717L, 2584L, 2829L, 2726L, 2685L, 2866L,
          2793L, 2614L, 2636L, 2907L, 2822L, 2932L, 2882L, 2882L, 2650L,
          2929L, 2809L, 2737L, 3623L, 3607L, 3584L, 3576L, 3680L, 2831L,
          2779L, 2915L, 2875L, 2712L, 3641L, 3590L, 3556L, 3584L, 2718L,
          2856L, 2674L, 2659L, 3640L, 3656L, 3686L, 2726L, 2685L, 2866L,
          2793L, 3516L, 3552L, 3513L, 3579L, 2932L, 2882L, 2882L, 2831L,
          2779L, 2915L, 2875L, 2712L, 2730L, 2793L, 2779L, 2772L, 2692L,
          2718L, 2856L, 2674L, 2659L, 2717L, 2584L, 2829L, 2726L, 2685L,
          2866L, 2793L, 2614L, 2636L, 2907L, 2822L, 2932L, 2882L, 2882L,
          2650L, 2929L, 2809L, 2737L, 3623L, 3607L, 3584L, 3576L, 3680L,
          2831L, 2779L, 2915L, 2875L, 2712L, 3641L, 3590L, 3556L, 3584L,
          2718L, 2856L, 2674L, 2659L, 3640L, 3656L, 3686L, 2726L, 2685L,
          2866L, 2793L, 3516L, 3552L, 3513L, 3579L, 2932L, 2882L, 2882L,
          2711L, 3129L, 2786L, 2833L, 2754L, 2771L, 2856L, 2779L, 2909L,
          2750L, 2866L, 2863L, 2804L, 2704L, 2636L, 2929L, 2711L, 3129L,
          2786L, 2833L, 2754L, 2771L, 2856L, 2779L, 2909L, 2750L, 2866L,
          2863L, 2804L, 2704L, 2636L, 2929L, 3226L, 3121L, 3867L, 3319L,
          3426L, 3269L, 3680L, 3357L, 2711L, 3129L, 2786L, 2833L, 2754L,
          2771L, 2856L, 2779L, 3226L, 3121L, 3867L, 3319L, 3426L, 3269L,
          3680L, 3357L, 2711L, 3129L, 2786L, 2833L, 2754L, 2771L, 2856L,
          2779L), Word = structure(c(2L, 2L, 2L, 2L, 2L, 4L, 4L, 4L,
          4L, 4L, 2L, 2L, 2L, 2L, 4L, 4L, 4L, 2L, 2L, 2L, 2L, 4L, 4L,
          4L, 4L, 2L, 2L, 2L, 4L, 4L, 4L, 4L, 1L, 1L, 1L, 1L, 1L, 2L,
          2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 1L, 1L, 1L,
          2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 4L, 4L, 4L, 4L, 4L, 2L, 2L, 2L, 2L, 4L, 4L, 4L, 2L, 2L,
          2L, 2L, 4L, 4L, 4L, 4L, 2L, 2L, 2L, 4L, 4L, 4L, 4L, 1L, 1L,
          1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 2L, 2L, 2L,
          2L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 2L, 2L, 2L,
          3L, 3L, 3L, 3L, 3L, 3L, 3L, 2L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L), .Label = c("heed", "hoed", "hoed ", "whod"
          ), class = "factor"), Vowel = structure(c(2L, 2L, 2L, 2L,
          2L, 4L, 4L, 4L, 4L, 4L, 2L, 2L, 2L, 2L, 4L, 4L, 4L, 2L, 2L,
          2L, 2L, 4L, 4L, 4L, 4L, 2L, 2L, 2L, 4L, 4L, 4L, 4L, 1L, 1L,
          1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 2L, 2L, 2L,
          2L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 4L, 4L, 4L, 4L, 4L, 2L, 2L, 2L, 2L, 4L,
          4L, 4L, 2L, 2L, 2L, 2L, 4L, 4L, 4L, 4L, 2L, 2L, 2L, 4L, 4L,
          4L, 4L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L, 1L, 1L, 1L,
          1L, 2L, 2L, 2L, 2L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 1L, 1L, 1L,
          1L, 2L, 2L, 2L, 3L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L), .Label = c("i", "o", "o ",
          "u"), class = "factor"), F1.Mean = c(564L, 564L, 564L, 564L,
          564L, 394L, 394L, 394L, 394L, 394L, 564L, 564L, 564L, 564L,
          394L, 394L, 394L, 564L, 564L, 564L, 564L, 394L, 394L, 394L,
          394L, 564L, 564L, 564L, 394L, 394L, 394L, 394L, 398L, 398L,
          398L, 398L, 398L, 564L, 564L, 564L, 564L, 564L, 398L, 398L,
          398L, 398L, 564L, 564L, 564L, 564L, 398L, 398L, 398L, 564L,
          564L, 564L, 564L, 398L, 398L, 398L, 398L, 564L, 564L, 564L,
          564L, 564L, 564L, 564L, 564L, 394L, 394L, 394L, 394L, 394L,
          564L, 564L, 564L, 564L, 394L, 394L, 394L, 564L, 564L, 564L,
          564L, 394L, 394L, 394L, 394L, 564L, 564L, 564L, 394L, 394L,
          394L, 394L, 398L, 398L, 398L, 398L, 398L, 564L, 564L, 564L,
          564L, 564L, 398L, 398L, 398L, 398L, 564L, 564L, 564L, 564L,
          398L, 398L, 398L, 564L, 564L, 564L, 564L, 398L, 398L, 398L,
          398L, 564L, 564L, 564L, 627L, 627L, 614L, 614L, 614L, 614L,
          566L, 566L, 432L, 432L, 327L, 327L, 415L, 415L, 393L, 393L,
          627L, 627L, 614L, 614L, 614L, 614L, 566L, 566L, 432L, 432L,
          327L, 327L, 415L, 415L, 393L, 393L, 397L, 397L, 292L, 292L,
          417L, 417L, 398L, 398L, 627L, 627L, 614L, 614L, 614L, 614L,
          566L, 566L, 397L, 397L, 292L, 292L, 417L, 417L, 398L, 398L,
          627L, 627L, 614L, 614L, 614L, 614L, 566L, 566L), F2.Mean = c(1328L,
          1328L, 1328L, 1328L, 1328L, 1496L, 1496L, 1496L, 1496L, 1496L,
          1328L, 1328L, 1328L, 1328L, 1496L, 1496L, 1496L, 1328L, 1328L,
          1328L, 1328L, 1496L, 1496L, 1496L, 1496L, 1328L, 1328L, 1328L,
          1496L, 1496L, 1496L, 1496L, 2969L, 2969L, 2969L, 2969L, 2969L,
          1328L, 1328L, 1328L, 1328L, 1328L, 2969L, 2969L, 2969L, 2969L,
          1328L, 1328L, 1328L, 1328L, 2969L, 2969L, 2969L, 1328L, 1328L,
          1328L, 1328L, 2969L, 2969L, 2969L, 2969L, 1328L, 1328L, 1328L,
          1328L, 1328L, 1328L, 1328L, 1328L, 1496L, 1496L, 1496L, 1496L,
          1496L, 1328L, 1328L, 1328L, 1328L, 1496L, 1496L, 1496L, 1328L,
          1328L, 1328L, 1328L, 1496L, 1496L, 1496L, 1496L, 1328L, 1328L,
          1328L, 1496L, 1496L, 1496L, 1496L, 2969L, 2969L, 2969L, 2969L,
          2969L, 1328L, 1328L, 1328L, 1328L, 1328L, 2969L, 2969L, 2969L,
          2969L, 1328L, 1328L, 1328L, 1328L, 2969L, 2969L, 2969L, 1328L,
          1328L, 1328L, 1328L, 2969L, 2969L, 2969L, 2969L, 1328L, 1328L,
          1328L, 1250L, 1250L, 1247L, 1247L, 1247L, 1247L, 1357L, 1357L,
          1292L, 1292L, 1157L, 1157L, 1746L, 1746L, 1455L, 1455L, 1250L,
          1250L, 1247L, 1247L, 1247L, 1247L, 1357L, 1357L, 1292L, 1292L,
          1157L, 1157L, 1746L, 1746L, 1455L, 1455L, 2828L, 2828L, 2763L,
          2763L, 2721L, 2721L, 2969L, 2969L, 1250L, 1250L, 1247L, 1247L,
          1247L, 1247L, 1357L, 1357L, 2828L, 2828L, 2763L, 2763L, 2721L,
          2721L, 2969L, 2969L, 1250L, 1250L, 1247L, 1247L, 1247L, 1247L,
          1357L, 1357L), Distance = c(16L, 54L, 55L, 29L, 76L, 13L,
          25L, 43L, 66L, 43L, 34L, 50L, 4L, 31L, 72L, 67L, 83L, 25L,
          74L, 56L, 11L, 52L, 44L, 5L, 20L, 34L, 25L, 81L, 80L, 58L,
          82L, 52L, 36L, 58L, 25L, 7L, 24L, 16L, 54L, 55L, 29L, 76L,
          28L, 56L, 18L, 30L, 34L, 50L, 4L, 31L, 42L, 40L, 14L, 25L,
          74L, 56L, 11L, 13L, 23L, 38L, 30L, 34L, 25L, 81L, 16L, 54L,
          55L, 29L, 76L, 13L, 25L, 43L, 66L, 43L, 34L, 50L, 4L, 31L,
          72L, 67L, 83L, 25L, 74L, 56L, 11L, 52L, 44L, 5L, 20L, 34L,
          25L, 81L, 80L, 58L, 82L, 52L, 36L, 58L, 25L, 7L, 24L, 16L,
          54L, 55L, 29L, 76L, 28L, 56L, 18L, 30L, 34L, 50L, 4L, 31L,
          42L, 40L, 14L, 25L, 74L, 56L, 11L, 13L, 23L, 38L, 30L, 34L,
          25L, 81L, 8L, 7L, 48L, 19L, 110L, 115L, 22L, 27L, 22L, 61L,
          39L, 52L, 103L, 87L, 3L, 17L, 8L, 7L, 48L, 19L, 110L, 115L,
          22L, 27L, 22L, 61L, 39L, 52L, 103L, 87L, 3L, 17L, 52L, 46L,
          17L, 13L, 37L, 4L, 24L, 25L, 8L, 7L, 48L, 19L, 110L, 115L,
          22L, 27L, 52L, 46L, 17L, 13L, 37L, 4L, 24L, 25L, 8L, 7L,
          48L, 19L, 110L, 115L, 22L, 27L), Included = structure(c(1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L), .Label = "Yes", class = "factor"),
          Talker = structure(c(4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 1L,
          1L, 2L, 2L, 3L, 3L, 4L, 4L, 1L, 1L, 2L, 2L, 3L, 3L, 4L, 4L,
          1L, 1L, 2L, 2L, 3L, 3L, 4L, 4L, 1L, 1L, 2L, 2L, 3L, 3L, 4L,
          4L, 1L, 1L, 2L, 2L, 3L, 3L, 4L, 4L, 1L, 1L, 2L, 2L, 3L, 3L,
          4L, 4L, 1L, 1L, 2L, 2L, 3L, 3L, 4L, 4L, 1L, 1L, 2L, 2L, 3L,
          3L, 4L, 4L), .Label = c("T1 ", "T2", "T3", "T4"), class = "factor"),
          Ambiguity = structure(c(1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L), .Label = c("High", "Low"), class = "factor"),
          Variability = structure(c(2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L), .Label = c("Mixed", "Single"), class = "factor"),
          Consistency = structure(c(1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L), .Label = c("Consistent", "Inconsistent"), class = "factor"),
          Fake = c(477, 497, 560, 543, 549, 466, 486, 516, 525, 534,
          496, 580, 587, 557, 517, 563, 524, 546, 547, 596, 632, 544,
          497, 592, 544, 612, 642, 545, 574, 602, 532, 522, 519, 534,
          580, 587, 557, 477, 497, 560, 543, 549, 574, 543, 603, 582,
          496, 580, 587, 557, 511, 622, 604, 546, 547, 596, 632, 634,
          556, 536, 588, 612, 642, 545, 477, 497, 560, 543, 549, 466,
          486, 516, 525, 534, 496, 580, 587, 557, 517, 563, 524, 546,
          547, 596, 632, 544, 497, 592, 544, 612, 642, 545, 574, 602,
          532, 522, 519, 534, 580, 587, 557, 477, 497, 560, 543, 549,
          574, 543, 603, 582, 496, 580, 587, 557, 511, 622, 604, 546,
          547, 596, 632, 634, 556, 536, 588, 612, 642, 545, 452, 547,
          510, 663, 470, 503, 600, 517, 491, 505, 641, 581, 520, 485,
          517, 622, 452, 547, 510, 663, 470, 503, 600, 517, 491, 505,
          641, 581, 520, 485, 517, 622, 510, 458, 558, 638, 483, 538,
          577, 600, 452, 547, 510, 663, 470, 503, 600, 517, 510, 458,
          558, 638, 483, 538, 577, 600, 452, 547, 510, 663, 470, 503,
          600, 517), Check = c(20, 20, 20, 20, 20, 20, 20, 20, 20,
          20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20,
          20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20,
          20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20,
          20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20,
          20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20,
          20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20,
          20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20,
          20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 0,
          0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
          0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
          0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
          0, 0, 0, 0, 0, 0)), row.names = c(NA, -192L), class = "data.frame")

答:
We can check multiple conditions with & or |.  Here, we would need & because both the conditions should be satisfied

```<code>option1$Surgical <- ifelse(option1$Variability == "Single" &
       option1$Duration > 625, option1$Duration - 20, option1$Duration)
</code>```

Body:
I am trying to use an if-else statement to create a column in my data set. I want this if-else statement to create a column called "Surgical" in the df "option1" that displays the value of the column "Duration" subtracted by 20 ONLY IF the value in Duration is above 625, AND the factor "Single" is indicated in the column "Variability".
I have tried the following code:

option1$Surgical <- ifelse(option1$Variability == "Single", option1$Duration - 20, option1$Duration)

Any insight into how to specify the "only if the value is greater than 625" portion is appreciated!!

Df "option 1" for reference.

dput(option1)
      structure(list(Stimulus = structure(c(36L, 37L, 38L, 39L, 40L,
      41L, 42L, 43L, 44L, 45L, 50L, 51L, 52L, 53L, 54L, 55L, 56L, 60L,
      61L, 62L, 63L, 64L, 65L, 66L, 67L, 73L, 74L, 75L, 76L, 77L, 78L,
      79L, 31L, 32L, 33L, 34L, 35L, 36L, 37L, 38L, 39L, 40L, 46L, 47L,
      48L, 49L, 50L, 51L, 52L, 53L, 57L, 58L, 59L, 60L, 61L, 62L, 63L,
      69L, 70L, 71L, 72L, 73L, 74L, 75L, 36L, 37L, 38L, 39L, 40L, 41L,
      42L, 43L, 44L, 45L, 50L, 51L, 52L, 53L, 54L, 55L, 56L, 60L, 61L,
      62L, 63L, 64L, 65L, 66L, 67L, 73L, 74L, 75L, 76L, 77L, 78L, 79L,
      31L, 32L, 33L, 34L, 35L, 36L, 37L, 38L, 39L, 40L, 46L, 47L, 48L,
      49L, 50L, 51L, 52L, 53L, 57L, 58L, 59L, 60L, 61L, 62L, 63L, 69L,
      70L, 71L, 72L, 73L, 74L, 75L, 7L, 9L, 12L, 18L, 28L, 26L, 51L,
      37L, 3L, 2L, 19L, 14L, 27L, 23L, 65L, 77L, 7L, 9L, 12L, 18L,
      28L, 26L, 51L, 37L, 3L, 2L, 19L, 14L, 27L, 23L, 65L, 77L, 5L,
      11L, 20L, 16L, 30L, 25L, 35L, 33L, 7L, 9L, 12L, 18L, 28L, 26L,
      51L, 37L, 5L, 11L, 20L, 16L, 30L, 25L, 35L, 33L, 7L, 9L, 12L,
      18L, 28L, 26L, 51L, 37L), .Label = c("t1_block2_hoed3.mp3", "t1_block2_whod3.mp3",
      "t1_block2_whod4.mp3", "t1_block2_whod5.mp3", "t1_block3_heed2.mp3",
      "t1_block3_heed5.mp3", "t1_block3_hoed1.mp3", "t1_block3_hoed2.mp3",
      "t1_block3_hoed4.mp3", "t1_block3_whod3.mp3", "t1_block4_heed5.mp3",
      "t2_block1_hoed3.mp3", "t2_block1_whod1.mp3", "t2_block1_whod2.mp3",
      "t2_block1_whod4.mp3", "t2_block2_heed3.mp3", "t2_block2_hoed5.mp3",
      "t2_block3_hoed1.mp3", "t2_block3_whod1.mp3", "t2_block4_heed2.mp3",
      "t2_block4_heed5.mp3", "t3_block1_heed1.mp3", "t3_block1_whod2.mp3",
      "t3_block1_whod5.mp3", "t3_block2_heed5.mp3", "t3_block2_hoed2.mp3",
      "t3_block2_whod5.mp3", "t3_block3_hoed1.mp3", "t3_block3_hoed4.mp3",
      "t3_block4_heed3.mp3", "t4_block1_heed1.mp3", "t4_block1_heed2.mp3",
      "t4_block1_heed3.mp3", "t4_block1_heed4.mp3", "t4_block1_heed5.mp3",
      "t4_block1_hoed1.mp3", "t4_block1_hoed2.mp3", "t4_block1_hoed3.mp3",
      "t4_block1_hoed4.mp3", "t4_block1_hoed5.mp3", "t4_block1_whod1.mp3",
      "t4_block1_whod2.mp3", "t4_block1_whod3.mp3", "t4_block1_whod4.mp3",
      "t4_block1_whod5.mp3", "t4_block2_heed1.mp3", "t4_block2_heed2.mp3",
      "t4_block2_heed4.mp3", "t4_block2_heed5.mp3", "t4_block2_hoed1.mp3",
      "t4_block2_hoed3.mp3", "t4_block2_hoed4.mp3", "t4_block2_hoed5.mp3",
      "t4_block2_whod2.mp3", "t4_block2_whod4.mp3", "t4_block2_whod5.mp3",
      "t4_block3_heed1.mp3", "t4_block3_heed4.mp3", "t4_block3_heed5.mp3",
      "t4_block3_hoed1.mp3", "t4_block3_hoed2.mp3", "t4_block3_hoed4.mp3",
      "t4_block3_hoed5.mp3", "t4_block3_whod1.mp3", "t4_block3_whod2.mp3",
      "t4_block3_whod3.mp3", "t4_block3_whod5.mp3", "t4_block4_heed1.mp3",
      "t4_block4_heed2.mp3", "t4_block4_heed3.mp3", "t4_block4_heed4.mp3",
      "t4_block4_heed5.mp3", "t4_block4_hoed1.mp3", "t4_block4_hoed2.mp3",
      "t4_block4_hoed3.mp3", "t4_block4_whod1.mp3", "t4_block4_whod2.mp3",
      "t4_block4_whod3.mp3", "t4_block4_whod5.mp3"), class = "factor"),
          Duration = c(497L, 517L, 580L, 563L, 569L, 486L, 506L, 536L,
          545L, 554L, 516L, 600L, 607L, 577L, 537L, 583L, 544L, 566L,
          567L, 616L, 652L, 564L, 517L, 612L, 564L, 632L, 662L, 565L,
          594L, 622L, 552L, 542L, 539L, 554L, 600L, 607L, 577L, 497L,
          517L, 580L, 563L, 569L, 594L, 563L, 623L, 602L, 516L, 600L,
          607L, 577L, 531L, 642L, 624L, 566L, 567L, 616L, 652L, 654L,
          576L, 556L, 608L, 632L, 662L, 565L, 497L, 517L, 580L, 563L,
          569L, 486L, 506L, 536L, 545L, 554L, 516L, 600L, 607L, 577L,
          537L, 583L, 544L, 566L, 567L, 616L, 652L, 564L, 517L, 612L,
          564L, 632L, 662L, 565L, 594L, 622L, 552L, 542L, 539L, 554L,
          600L, 607L, 577L, 497L, 517L, 580L, 563L, 569L, 594L, 563L,
          623L, 602L, 516L, 600L, 607L, 577L, 531L, 642L, 624L, 566L,
          567L, 616L, 652L, 654L, 576L, 556L, 608L, 632L, 662L, 565L,
          452L, 547L, 510L, 663L, 470L, 503L, 600L, 517L, 491L, 505L,
          641L, 581L, 520L, 485L, 517L, 622L, 452L, 547L, 510L, 663L,
          470L, 503L, 600L, 517L, 491L, 505L, 641L, 581L, 520L, 485L,
          517L, 622L, 510L, 458L, 558L, 638L, 483L, 538L, 577L, 600L,
          452L, 547L, 510L, 663L, 470L, 503L, 600L, 517L, 510L, 458L,
          558L, 638L, 483L, 538L, 577L, 600L, 452L, 547L, 510L, 663L,
          470L, 503L, 600L, 517L), F0 = c(196L, 204L, 204L, 197L, 203L,
          216L, 208L, 223L, 213L, 219L, 196L, 202L, 205L, 202L, 208L,
          205L, 206L, 197L, 202L, 195L, 200L, 201L, 210L, 202L, 208L,
          195L, 196L, 195L, 205L, 208L, 203L, 203L, 212L, 213L, 210L,
          206L, 204L, 196L, 204L, 204L, 197L, 203L, 201L, 198L, 199L,
          203L, 196L, 202L, 205L, 202L, 193L, 195L, 208L, 197L, 202L,
          195L, 200L, 201L, 195L, 205L, 202L, 195L, 196L, 195L, 196L,
          204L, 204L, 197L, 203L, 216L, 208L, 223L, 213L, 219L, 196L,
          202L, 205L, 202L, 208L, 205L, 206L, 197L, 202L, 195L, 200L,
          201L, 210L, 202L, 208L, 195L, 196L, 195L, 205L, 208L, 203L,
          203L, 212L, 213L, 210L, 206L, 204L, 196L, 204L, 204L, 197L,
          203L, 201L, 198L, 199L, 203L, 196L, 202L, 205L, 202L, 193L,
          195L, 208L, 197L, 202L, 195L, 200L, 201L, 195L, 205L, 202L,
          195L, 196L, 195L, 215L, 219L, 219L, 220L, 199L, 202L, 202L,
          204L, 224L, 231L, 238L, 240L, 217L, 212L, 210L, 208L, 215L,
          219L, 219L, 220L, 199L, 202L, 202L, 204L, 224L, 231L, 238L,
          240L, 217L, 212L, 210L, 208L, 230L, 223L, 219L, 221L, 199L,
          200L, 204L, 210L, 215L, 219L, 219L, 220L, 199L, 202L, 202L,
          204L, 230L, 223L, 219L, 221L, 199L, 200L, 204L, 210L, 215L,
          219L, 219L, 220L, 199L, 202L, 202L, 204L), F1 = c(576L, 553L,
          579L, 586L, 601L, 398L, 390L, 398L, 389L, 404L, 587L, 560L,
          562L, 553L, 393L, 397L, 382L, 553L, 592L, 556L, 571L, 387L,
          392L, 398L, 400L, 580L, 580L, 554L, 403L, 391L, 388L, 393L,
          382L, 375L, 384L, 392L, 388L, 576L, 553L, 579L, 586L, 601L,
          387L, 393L, 402L, 406L, 587L, 560L, 562L, 553L, 388L, 391L,
          412L, 553L, 592L, 556L, 571L, 410L, 404L, 401L, 420L, 580L,
          580L, 554L, 576L, 553L, 579L, 586L, 601L, 398L, 390L, 398L,
          389L, 404L, 587L, 560L, 562L, 553L, 393L, 397L, 382L, 553L,
          592L, 556L, 571L, 387L, 392L, 398L, 400L, 580L, 580L, 554L,
          403L, 391L, 388L, 393L, 382L, 375L, 384L, 392L, 388L, 576L,
          553L, 579L, 586L, 601L, 387L, 393L, 402L, 406L, 587L, 560L,
          562L, 553L, 388L, 391L, 412L, 553L, 592L, 556L, 571L, 410L,
          404L, 401L, 420L, 580L, 580L, 554L, 620L, 630L, 602L, 605L,
          571L, 573L, 560L, 553L, 434L, 417L, 306L, 319L, 414L, 419L,
          392L, 391L, 620L, 630L, 602L, 605L, 571L, 573L, 560L, 553L,
          434L, 417L, 306L, 319L, 414L, 419L, 392L, 391L, 448L, 441L,
          293L, 291L, 420L, 420L, 388L, 384L, 620L, 630L, 602L, 605L,
          571L, 573L, 560L, 553L, 448L, 441L, 293L, 291L, 420L, 420L,
          388L, 384L, 620L, 630L, 602L, 605L, 571L, 573L, 560L, 553L
          ), F2 = c(1339L, 1381L, 1381L, 1347L, 1394L, 1484L, 1521L,
          1539L, 1430L, 1454L, 1353L, 1378L, 1325L, 1357L, 1424L, 1563L,
          1578L, 1350L, 1397L, 1273L, 1319L, 1548L, 1452L, 1499L, 1515L,
          1358L, 1347L, 1248L, 1575L, 1438L, 1414L, 1548L, 3001L, 2916L,
          2948L, 2973L, 2947L, 1339L, 1381L, 1381L, 1347L, 1394L, 2943L,
          2913L, 2987L, 2940L, 1353L, 1378L, 1325L, 1357L, 3010L, 3008L,
          2972L, 1350L, 1397L, 1273L, 1319L, 2963L, 2991L, 3007L, 2989L,
          1358L, 1347L, 1248L, 1339L, 1381L, 1381L, 1347L, 1394L, 1484L,
          1521L, 1539L, 1430L, 1454L, 1353L, 1378L, 1325L, 1357L, 1424L,
          1563L, 1578L, 1350L, 1397L, 1273L, 1319L, 1548L, 1452L, 1499L,
          1515L, 1358L, 1347L, 1248L, 1575L, 1438L, 1414L, 1548L, 3001L,
          2916L, 2948L, 2973L, 2947L, 1339L, 1381L, 1381L, 1347L, 1394L,
          2943L, 2913L, 2987L, 2940L, 1353L, 1378L, 1325L, 1357L, 3010L,
          3008L, 2972L, 1350L, 1397L, 1273L, 1319L, 2963L, 2991L, 3007L,
          2989L, 1358L, 1347L, 1248L, 1247L, 1244L, 1293L, 1264L, 1348L,
          1354L, 1378L, 1381L, 1314L, 1233L, 1190L, 1208L, 1643L, 1659L,
          1452L, 1438L, 1247L, 1244L, 1293L, 1264L, 1348L, 1354L, 1378L,
          1381L, 1314L, 1233L, 1190L, 1208L, 1643L, 1659L, 1452L, 1438L,
          2837L, 2816L, 2780L, 2776L, 2684L, 2718L, 2947L, 2948L, 1247L,
          1244L, 1293L, 1264L, 1348L, 1354L, 1378L, 1381L, 2837L, 2816L,
          2780L, 2776L, 2684L, 2718L, 2947L, 2948L, 1247L, 1244L, 1293L,
          1264L, 1348L, 1354L, 1378L, 1381L), F3 = c(2831L, 2779L,
          2915L, 2875L, 2712L, 2730L, 2793L, 2779L, 2772L, 2692L, 2718L,
          2856L, 2674L, 2659L, 2717L, 2584L, 2829L, 2726L, 2685L, 2866L,
          2793L, 2614L, 2636L, 2907L, 2822L, 2932L, 2882L, 2882L, 2650L,
          2929L, 2809L, 2737L, 3623L, 3607L, 3584L, 3576L, 3680L, 2831L,
          2779L, 2915L, 2875L, 2712L, 3641L, 3590L, 3556L, 3584L, 2718L,
          2856L, 2674L, 2659L, 3640L, 3656L, 3686L, 2726L, 2685L, 2866L,
          2793L, 3516L, 3552L, 3513L, 3579L, 2932L, 2882L, 2882L, 2831L,
          2779L, 2915L, 2875L, 2712L, 2730L, 2793L, 2779L, 2772L, 2692L,
          2718L, 2856L, 2674L, 2659L, 2717L, 2584L, 2829L, 2726L, 2685L,
          2866L, 2793L, 2614L, 2636L, 2907L, 2822L, 2932L, 2882L, 2882L,
          2650L, 2929L, 2809L, 2737L, 3623L, 3607L, 3584L, 3576L, 3680L,
          2831L, 2779L, 2915L, 2875L, 2712L, 3641L, 3590L, 3556L, 3584L,
          2718L, 2856L, 2674L, 2659L, 3640L, 3656L, 3686L, 2726L, 2685L,
          2866L, 2793L, 3516L, 3552L, 3513L, 3579L, 2932L, 2882L, 2882L,
          2711L, 3129L, 2786L, 2833L, 2754L, 2771L, 2856L, 2779L, 2909L,
          2750L, 2866L, 2863L, 2804L, 2704L, 2636L, 2929L, 2711L, 3129L,
          2786L, 2833L, 2754L, 2771L, 2856L, 2779L, 2909L, 2750L, 2866L,
          2863L, 2804L, 2704L, 2636L, 2929L, 3226L, 3121L, 3867L, 3319L,
          3426L, 3269L, 3680L, 3357L, 2711L, 3129L, 2786L, 2833L, 2754L,
          2771L, 2856L, 2779L, 3226L, 3121L, 3867L, 3319L, 3426L, 3269L,
          3680L, 3357L, 2711L, 3129L, 2786L, 2833L, 2754L, 2771L, 2856L,
          2779L), Word = structure(c(2L, 2L, 2L, 2L, 2L, 4L, 4L, 4L,
          4L, 4L, 2L, 2L, 2L, 2L, 4L, 4L, 4L, 2L, 2L, 2L, 2L, 4L, 4L,
          4L, 4L, 2L, 2L, 2L, 4L, 4L, 4L, 4L, 1L, 1L, 1L, 1L, 1L, 2L,
          2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 1L, 1L, 1L,
          2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 4L, 4L, 4L, 4L, 4L, 2L, 2L, 2L, 2L, 4L, 4L, 4L, 2L, 2L,
          2L, 2L, 4L, 4L, 4L, 4L, 2L, 2L, 2L, 4L, 4L, 4L, 4L, 1L, 1L,
          1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 2L, 2L, 2L,
          2L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 2L, 2L, 2L,
          3L, 3L, 3L, 3L, 3L, 3L, 3L, 2L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L), .Label = c("heed", "hoed", "hoed ", "whod"
          ), class = "factor"), Vowel = structure(c(2L, 2L, 2L, 2L,
          2L, 4L, 4L, 4L, 4L, 4L, 2L, 2L, 2L, 2L, 4L, 4L, 4L, 2L, 2L,
          2L, 2L, 4L, 4L, 4L, 4L, 2L, 2L, 2L, 4L, 4L, 4L, 4L, 1L, 1L,
          1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 2L, 2L, 2L,
          2L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 4L, 4L, 4L, 4L, 4L, 2L, 2L, 2L, 2L, 4L,
          4L, 4L, 2L, 2L, 2L, 2L, 4L, 4L, 4L, 4L, 2L, 2L, 2L, 4L, 4L,
          4L, 4L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L, 1L, 1L, 1L,
          1L, 2L, 2L, 2L, 2L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 1L, 1L, 1L,
          1L, 2L, 2L, 2L, 3L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L), .Label = c("i", "o", "o ",
          "u"), class = "factor"), F1.Mean = c(564L, 564L, 564L, 564L,
          564L, 394L, 394L, 394L, 394L, 394L, 564L, 564L, 564L, 564L,
          394L, 394L, 394L, 564L, 564L, 564L, 564L, 394L, 394L, 394L,
          394L, 564L, 564L, 564L, 394L, 394L, 394L, 394L, 398L, 398L,
          398L, 398L, 398L, 564L, 564L, 564L, 564L, 564L, 398L, 398L,
          398L, 398L, 564L, 564L, 564L, 564L, 398L, 398L, 398L, 564L,
          564L, 564L, 564L, 398L, 398L, 398L, 398L, 564L, 564L, 564L,
          564L, 564L, 564L, 564L, 564L, 394L, 394L, 394L, 394L, 394L,
          564L, 564L, 564L, 564L, 394L, 394L, 394L, 564L, 564L, 564L,
          564L, 394L, 394L, 394L, 394L, 564L, 564L, 564L, 394L, 394L,
          394L, 394L, 398L, 398L, 398L, 398L, 398L, 564L, 564L, 564L,
          564L, 564L, 398L, 398L, 398L, 398L, 564L, 564L, 564L, 564L,
          398L, 398L, 398L, 564L, 564L, 564L, 564L, 398L, 398L, 398L,
          398L, 564L, 564L, 564L, 627L, 627L, 614L, 614L, 614L, 614L,
          566L, 566L, 432L, 432L, 327L, 327L, 415L, 415L, 393L, 393L,
          627L, 627L, 614L, 614L, 614L, 614L, 566L, 566L, 432L, 432L,
          327L, 327L, 415L, 415L, 393L, 393L, 397L, 397L, 292L, 292L,
          417L, 417L, 398L, 398L, 627L, 627L, 614L, 614L, 614L, 614L,
          566L, 566L, 397L, 397L, 292L, 292L, 417L, 417L, 398L, 398L,
          627L, 627L, 614L, 614L, 614L, 614L, 566L, 566L), F2.Mean = c(1328L,
          1328L, 1328L, 1328L, 1328L, 1496L, 1496L, 1496L, 1496L, 1496L,
          1328L, 1328L, 1328L, 1328L, 1496L, 1496L, 1496L, 1328L, 1328L,
          1328L, 1328L, 1496L, 1496L, 1496L, 1496L, 1328L, 1328L, 1328L,
          1496L, 1496L, 1496L, 1496L, 2969L, 2969L, 2969L, 2969L, 2969L,
          1328L, 1328L, 1328L, 1328L, 1328L, 2969L, 2969L, 2969L, 2969L,
          1328L, 1328L, 1328L, 1328L, 2969L, 2969L, 2969L, 1328L, 1328L,
          1328L, 1328L, 2969L, 2969L, 2969L, 2969L, 1328L, 1328L, 1328L,
          1328L, 1328L, 1328L, 1328L, 1328L, 1496L, 1496L, 1496L, 1496L,
          1496L, 1328L, 1328L, 1328L, 1328L, 1496L, 1496L, 1496L, 1328L,
          1328L, 1328L, 1328L, 1496L, 1496L, 1496L, 1496L, 1328L, 1328L,
          1328L, 1496L, 1496L, 1496L, 1496L, 2969L, 2969L, 2969L, 2969L,
          2969L, 1328L, 1328L, 1328L, 1328L, 1328L, 2969L, 2969L, 2969L,
          2969L, 1328L, 1328L, 1328L, 1328L, 2969L, 2969L, 2969L, 1328L,
          1328L, 1328L, 1328L, 2969L, 2969L, 2969L, 2969L, 1328L, 1328L,
          1328L, 1250L, 1250L, 1247L, 1247L, 1247L, 1247L, 1357L, 1357L,
          1292L, 1292L, 1157L, 1157L, 1746L, 1746L, 1455L, 1455L, 1250L,
          1250L, 1247L, 1247L, 1247L, 1247L, 1357L, 1357L, 1292L, 1292L,
          1157L, 1157L, 1746L, 1746L, 1455L, 1455L, 2828L, 2828L, 2763L,
          2763L, 2721L, 2721L, 2969L, 2969L, 1250L, 1250L, 1247L, 1247L,
          1247L, 1247L, 1357L, 1357L, 2828L, 2828L, 2763L, 2763L, 2721L,
          2721L, 2969L, 2969L, 1250L, 1250L, 1247L, 1247L, 1247L, 1247L,
          1357L, 1357L), Distance = c(16L, 54L, 55L, 29L, 76L, 13L,
          25L, 43L, 66L, 43L, 34L, 50L, 4L, 31L, 72L, 67L, 83L, 25L,
          74L, 56L, 11L, 52L, 44L, 5L, 20L, 34L, 25L, 81L, 80L, 58L,
          82L, 52L, 36L, 58L, 25L, 7L, 24L, 16L, 54L, 55L, 29L, 76L,
          28L, 56L, 18L, 30L, 34L, 50L, 4L, 31L, 42L, 40L, 14L, 25L,
          74L, 56L, 11L, 13L, 23L, 38L, 30L, 34L, 25L, 81L, 16L, 54L,
          55L, 29L, 76L, 13L, 25L, 43L, 66L, 43L, 34L, 50L, 4L, 31L,
          72L, 67L, 83L, 25L, 74L, 56L, 11L, 52L, 44L, 5L, 20L, 34L,
          25L, 81L, 80L, 58L, 82L, 52L, 36L, 58L, 25L, 7L, 24L, 16L,
          54L, 55L, 29L, 76L, 28L, 56L, 18L, 30L, 34L, 50L, 4L, 31L,
          42L, 40L, 14L, 25L, 74L, 56L, 11L, 13L, 23L, 38L, 30L, 34L,
          25L, 81L, 8L, 7L, 48L, 19L, 110L, 115L, 22L, 27L, 22L, 61L,
          39L, 52L, 103L, 87L, 3L, 17L, 8L, 7L, 48L, 19L, 110L, 115L,
          22L, 27L, 22L, 61L, 39L, 52L, 103L, 87L, 3L, 17L, 52L, 46L,
          17L, 13L, 37L, 4L, 24L, 25L, 8L, 7L, 48L, 19L, 110L, 115L,
          22L, 27L, 52L, 46L, 17L, 13L, 37L, 4L, 24L, 25L, 8L, 7L,
          48L, 19L, 110L, 115L, 22L, 27L), Included = structure(c(1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L), .Label = "Yes", class = "factor"),
          Talker = structure(c(4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L,
          4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 4L, 1L,
          1L, 2L, 2L, 3L, 3L, 4L, 4L, 1L, 1L, 2L, 2L, 3L, 3L, 4L, 4L,
          1L, 1L, 2L, 2L, 3L, 3L, 4L, 4L, 1L, 1L, 2L, 2L, 3L, 3L, 4L,
          4L, 1L, 1L, 2L, 2L, 3L, 3L, 4L, 4L, 1L, 1L, 2L, 2L, 3L, 3L,
          4L, 4L, 1L, 1L, 2L, 2L, 3L, 3L, 4L, 4L, 1L, 1L, 2L, 2L, 3L,
          3L, 4L, 4L), .Label = c("T1 ", "T2", "T3", "T4"), class = "factor"),
          Ambiguity = structure(c(1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L), .Label = c("High", "Low"), class = "factor"),
          Variability = structure(c(2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L), .Label = c("Mixed", "Single"), class = "factor"),
          Consistency = structure(c(1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L,
          1L, 1L, 1L, 1L), .Label = c("Consistent", "Inconsistent"), class = "factor"),
          Fake = c(477, 497, 560, 543, 549, 466, 486, 516, 525, 534,
          496, 580, 587, 557, 517, 563, 524, 546, 547, 596, 632, 544,
          497, 592, 544, 612, 642, 545, 574, 602, 532, 522, 519, 534,
          580, 587, 557, 477, 497, 560, 543, 549, 574, 543, 603, 582,
          496, 580, 587, 557, 511, 622, 604, 546, 547, 596, 632, 634,
          556, 536, 588, 612, 642, 545, 477, 497, 560, 543, 549, 466,
          486, 516, 525, 534, 496, 580, 587, 557, 517, 563, 524, 546,
          547, 596, 632, 544, 497, 592, 544, 612, 642, 545, 574, 602,
          532, 522, 519, 534, 580, 587, 557, 477, 497, 560, 543, 549,
          574, 543, 603, 582, 496, 580, 587, 557, 511, 622, 604, 546,
          547, 596, 632, 634, 556, 536, 588, 612, 642, 545, 452, 547,
          510, 663, 470, 503, 600, 517, 491, 505, 641, 581, 520, 485,
          517, 622, 452, 547, 510, 663, 470, 503, 600, 517, 491, 505,
          641, 581, 520, 485, 517, 622, 510, 458, 558, 638, 483, 538,
          577, 600, 452, 547, 510, 663, 470, 503, 600, 517, 510, 458,
          558, 638, 483, 538, 577, 600, 452, 547, 510, 663, 470, 503,
          600, 517), Check = c(20, 20, 20, 20, 20, 20, 20, 20, 20,
          20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20,
          20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20,
          20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20,
          20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20,
          20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20,
          20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20,
          20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20,
          20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 0,
          0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
          0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
          0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
          0, 0, 0, 0, 0, 0)), row.names = c(NA, -192L), class = "data.frame")

Body:
We can check multiple conditions with & or |.  Here, we would need & because both the conditions should be satisfied

option1$Surgical <- ifelse(option1$Variability == "Single" &
       option1$Duration > 625, option1$Duration - 20, option1$Duration)


来源: stackexchange

问:
How to write unit test for SpringBoot API having Spring Security configured
I have created a Spring Boot application containing various endpoints. Except for signup and login endpoints I've added a filter for other requests. All other requests should have:

Authorization  Bearer <token>

and requests goes through Spring Security filter chain which checks the user exists in the table or not via UserDetailService.

I would like to know how can I write unit tests for any GET/POST  API with Spring Security in place ?

One way i have in mind is to generate the actual token by calling signup API and then call other APIs with the Authorization token generated by Signup API.

OR

There might be some way to mock or skip the Authorization Bearer for unit tests

I wanted to know what is this the correct/best approach that's followed across?

答:
For my applications i have been using a conbination of MockUser annotation with a MockMvc bean. MockUser is able to populate Spring SecurityContext with a user and his principal, which includes his User object and GrantedAuthority (aka ROLEs). With this you can test your controllers without needing to create any token. It is easier and more decoupled from your autthentication process.

Like this:

```<code>@Test
@WithMockUser("admin")
void testAuthorize() throws Exception {
    this.mockMvc.perform(get("/objects")).andExpect(status().isOk());
}
</code>```

In Spring docs you can read more about. And you also have @WithAnonymousUser, to simulate anonnymouser, @WithUserDetails to put a custom UserDetailsService.

ContentLicense: CC BY-SA 4.0

Body:
For my applications i have been using a conbination of MockUser annotation with a MockMvc bean. MockUser is able to populate Spring SecurityContext with a user and his principal, which includes his User object and GrantedAuthority (aka ROLEs). With this you can test your controllers without needing to create any token. It is easier and more decoupled from your autthentication process.

Like this:

@Test
@WithMockUser("admin")
void testAuthorize() throws Exception {
    this.mockMvc.perform(get("/objects")).andExpect(status().isOk());
}

In Spring docs you can read more about. And you also have @WithAnonymousUser, to simulate anonnymouser, @WithUserDetails to put a custom UserDetailsService.


问:
JWT authentication with Blazor 0.9.0 and ASP.NET Core 3 preview 4
I followed this tutorial: https://medium.com/@st.mas29/microsoft-blazor-web-api-with-jwt-authentication-part-1-f33a44abab9d (which is for .NET core 2.2).

Here my Startup class

```<code>    public class Startup
    {
        // This method gets called by the runtime. Use this method to add services to the container.
        // For more information on how to configure your application, visit https://go.microsoft.com/fwlink/?LinkID=398940
        public IConfiguration Configuration { get; }
        public Startup (IConfiguration configuration)
        {
            Configuration = configuration;
        }

        public void ConfigureServices(IServiceCollection services)
        {
            services.AddMvc().AddNewtonsoftJson();
            //services.AddMvcCore().AddAuthorization().AddNewtonsoftJson();

            services.AddAuthentication(options =>
            {
                options.DefaultAuthenticateScheme = JwtBearerDefaults.AuthenticationScheme;
                options.DefaultChallengeScheme = JwtBearerDefaults.AuthenticationScheme;
            })
            .AddJwtBearer(options =>
            {
                options.TokenValidationParameters = new TokenValidationParameters
                {
                    ValidateIssuer = true,
                    ValidateAudience = true,
                    ValidateLifetime = true,
                    ValidateIssuerSigningKey = true,
                    ValidIssuer = Configuration["Jwt:Issuer"],
                    ValidAudience = Configuration["Jwt:Audience"],
                    IssuerSigningKey = new SymmetricSecurityKey(Encoding.UTF8.GetBytes(Configuration["Jwt:Key"]))
                };
            });

            services.AddResponseCompression(opts =>
            {
                opts.MimeTypes = ResponseCompressionDefaults.MimeTypes.Concat(
                    new[] { "application/octet-stream" });
            });

        }

        // This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
        public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
        {
            app.UseResponseCompression();

            if (env.IsDevelopment())
            {
                app.UseDeveloperExceptionPage();
                app.UseBlazorDebugging();
            }

            app.UseAuthentication();
            //app.UseAuthorization();

            app.UseRouting();

            app.UseEndpoints(endpoints =>
            {
                endpoints.MapDefaultControllerRoute();
            });

            app.UseBlazor<Client.Startup>();
        }
    }

</code>```

I also added [Authorize] on the Api controller SampleDataController.

I expected (as per the post) to get a 401 (Unauthorized) error when accessing the data, instead I get a complaint about missing authorization middleware

If I add app.UseAuthorization() (un-comment the line) the application works normally, without any error, retrieving the data as though the client is authorized.

What needs to be done to get a 401 when accessing the data?

答:
If you send a request with a an authorization token, and the server authorization is not setup in the Startup.cs file, the API will return an error saying <Called method> contains authorization metadata, but a middleware was not found that supports authorization...

The fix is to add the below lines in the Startup.cs file, BETWEEN app.UseRouting() and app.UseEndpoints(...):

```<code>            app.UseRouting();

            //AUTHORIZING
            app.UseAuthentication();
            app.UseAuthorization();

            app.UseEndpoints(endpoints =>
            {
                endpoints.MapRazorPages();
                endpoints.MapControllers();
                endpoints.MapFallbackToFile("index.html");
            });
</code>```

Body:
I followed this tutorial: https://medium.com/@st.mas29/microsoft-blazor-web-api-with-jwt-authentication-part-1-f33a44abab9d (which is for .NET core 2.2).

Here my Startup class

    public class Startup
    {
        // This method gets called by the runtime. Use this method to add services to the container.
        // For more information on how to configure your application, visit https://go.microsoft.com/fwlink/?LinkID=398940
        public IConfiguration Configuration { get; }
        public Startup (IConfiguration configuration)
        {
            Configuration = configuration;
        }

        public void ConfigureServices(IServiceCollection services)
        {
            services.AddMvc().AddNewtonsoftJson();
            //services.AddMvcCore().AddAuthorization().AddNewtonsoftJson();

            services.AddAuthentication(options =>
            {
                options.DefaultAuthenticateScheme = JwtBearerDefaults.AuthenticationScheme;
                options.DefaultChallengeScheme = JwtBearerDefaults.AuthenticationScheme;
            })
            .AddJwtBearer(options =>
            {
                options.TokenValidationParameters = new TokenValidationParameters
                {
                    ValidateIssuer = true,
                    ValidateAudience = true,
                    ValidateLifetime = true,
                    ValidateIssuerSigningKey = true,
                    ValidIssuer = Configuration["Jwt:Issuer"],
                    ValidAudience = Configuration["Jwt:Audience"],
                    IssuerSigningKey = new SymmetricSecurityKey(Encoding.UTF8.GetBytes(Configuration["Jwt:Key"]))
                };
            });

            services.AddResponseCompression(opts =>
            {
                opts.MimeTypes = ResponseCompressionDefaults.MimeTypes.Concat(
                    new[] { "application/octet-stream" });
            });

        }

        // This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
        public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
        {
            app.UseResponseCompression();

            if (env.IsDevelopment())
            {
                app.UseDeveloperExceptionPage();
                app.UseBlazorDebugging();
            }

            app.UseAuthentication();
            //app.UseAuthorization();

            app.UseRouting();

            app.UseEndpoints(endpoints =>
            {
                endpoints.MapDefaultControllerRoute();
            });

            app.UseBlazor<Client.Startup>();
        }
    }

I also added [Authorize] on the Api controller SampleDataController.

I expected (as per the post) to get a 401 (Unauthorized) error when accessing the data, instead I get a complaint about missing authorization middleware

If I add app.UseAuthorization() (un-comment the line) the application works normally, without any error, retrieving the data as though the client is authorized.

What needs to be done to get a 401 when accessing the data?

Body:
If you send a request with a an authorization token, and the server authorization is not setup in the Startup.cs file, the API will return an error saying <Called method> contains authorization metadata, but a middleware was not found that supports authorization...

The fix is to add the below lines in the Startup.cs file, BETWEEN app.UseRouting() and app.UseEndpoints(...):

            app.UseRouting();

            //AUTHORIZING
            app.UseAuthentication();
            app.UseAuthorization();

            app.UseEndpoints(endpoints =>
            {
                endpoints.MapRazorPages();
                endpoints.MapControllers();
                endpoints.MapFallbackToFile("index.html");
            });


问:
while loop condtion, difference between not equal and greater than
I'm doing a problem checking whether an integer is a palindrome. The logic is I convert it to string and then set the index of the first and the last. I loop through each first and last index and the values should match if they are palindrome. in the loop I increase the first index by one, I decrease the last index by one. So eventually they will meet in the half. The loop condition I originally had was if the indexes of both are not the same. but this gives me String index out of bounds exception. But then when I changed it to loop through as long as start is smaller than the end, it works. </p>

```<code>public boolean isPalindrome(int x) {

        if(x < 0) {
            return false;
        }
        String val = String.valueOf(x);

        int end = val.length()-1;
        int start = 0;
        while(start != end) {
            if(val.charAt(start) != val.charAt(end)) {
                return false;
            }
            start++;
            end--;
        }

        return true;
    }
    }
</code>```

<p>it works when I do    </p>

```<code> if(str.charAt(start++) < str.charAt(end--)) return false;
</code>```

答:
You have problem if the length is even number. For example if length is 4, you will have this run:

```<code>START | END
0     3
1     2
2     1
3     0
4     -1 <--- error
</code>```

as during whole time the condition of not-equality is true.

Body:
I'm doing a problem checking whether an integer is a palindrome. The logic is I convert it to string and then set the index of the first and the last. I loop through each first and last index and the values should match if they are palindrome. in the loop I increase the first index by one, I decrease the last index by one. So eventually they will meet in the half. The loop condition I originally had was if the indexes of both are not the same. but this gives me String index out of bounds exception. But then when I changed it to loop through as long as start is smaller than the end, it works.

public boolean isPalindrome(int x) {

        if(x < 0) {
            return false;
        }
        String val = String.valueOf(x);

        int end = val.length()-1;
        int start = 0;
        while(start != end) {
            if(val.charAt(start) != val.charAt(end)) {
                return false;
            }
            start++;
            end--;
        }

        return true;
    }
    }

it works when I do

 if(str.charAt(start++) < str.charAt(end--)) return false;

Body:
You have problem if the length is even number. For example if length is 4, you will have this run:

START | END
0     3
1     2
2     1
3     0
4     -1 <--- error

as during whole time the condition of not-equality is true.


问:
Routing Multiple Paths to same Route in YAML
I'm trying to translate an extensive set of routing configuration to the Spring Cloud Gateway Yaml DSL.

One problem I'm running into is (the exceedingly common case) where multiple paths should map to the same route.  That is, any incoming URL matching /abc/**, /def/**, or /ghi/** should be routed to some uri http://example.org (and have the same set of filters, etc. applied).

In the Fluent Java-based routing approach, this can be achieved via the .or(). method eg: r.path("/abc/**").or().path("/def/**").or().path("/fhi/**")...

How can this same functionality be achieved via the YAML-based route config?

Edit: I see in the docs:  https://cloud.spring.io/spring-cloud-gateway/single/spring-cloud-gateway.html#gateway-request-predicates-factories

"Multiple Route Predicate Factories can be combined and are combined
  via logical and"

Is there another way to achieve this OR-ing of path predicates via Yaml without declaring multiple routes?  Can something be overridden to support this?

答:
You probably have already got the answer. But for the record, I would say you can add multiple paths for the predicates as follows:</p>

```<code>spring:
  cloud:
    gateway:
      routes:
        - id: instructors_route
          uri: lb://INSTRUCTOR-SERVICE/
          predicates:
            - Path=/api/v1/instructors**,/api/v1/countries**
</code>```

Body:
You probably have already got the answer. But for the record, I would say you can add multiple paths for the predicates as follows:

spring:
  cloud:
    gateway:
      routes:
        - id: instructors_route
          uri: lb://INSTRUCTOR-SERVICE/
          predicates:
            - Path=/api/v1/instructors**,/api/v1/countries**


问:
Django and FCM to send push notifications
What's the correct way to use fcm-django using a custom Device-info model or a possibility to extend FCMDevice with more attributes.

For example, I need to store into the device info some additional fields like language, position  (lat/lng), app version, vendor etc.

I'm new for FCM but for me, at the moment, It's not very clear the device registration flow.
My current project is a backend service for mobile apps. So, I have some REST service using djnago-rest-framework.

I already have an API to register/update a mobile device. Can I reuse it adding the FCM registration-id?

答:
You can define your custom FCMDevice class by extending AbstactFCMDevice class as follows:

```<code>from fcm_django.models import AbstractFCMDevice
from django.db import models

class CustomFCMDevice(AbstractFCMDevice):
    language = models.CharField(max_length=35, blank=False)
    position = models.CharField(max_length=35, blank=False)
    app_version = models.CharField(max_length=35, blank=False)
    ...
    ..
</code>```

you can then use your custom class to get your queryset:

```<code>from custom_fcm_django.models import CustomFCMDevice

device = CustomFCMDevice.objects.all().first()

device.send_message(title="Title", body="Message", icon=..., data={"test": "test"})
</code>```

you can use django rest framework APIView to create your API endpoints, for example:

```<code>from rest_framework.views import APIView

class FCMDevicesListAPIView(APIView):

permission_classes = (IsAuthenticated, )

def get(self, request):
    queryset = CustomFCMDevice.objects.all()
    serializer = FCMDeviceSerializer(queryset, many=True)
    return Response(serializer.data)
</code>```

Body:
You can define your custom FCMDevice class by extending AbstactFCMDevice class as follows:

from fcm_django.models import AbstractFCMDevice
from django.db import models

class CustomFCMDevice(AbstractFCMDevice):
    language = models.CharField(max_length=35, blank=False)
    position = models.CharField(max_length=35, blank=False)
    app_version = models.CharField(max_length=35, blank=False)
    ...
    ..

you can then use your custom class to get your queryset:

from custom_fcm_django.models import CustomFCMDevice

device = CustomFCMDevice.objects.all().first()

device.send_message(title="Title", body="Message", icon=..., data={"test": "test"})

you can use django rest framework APIView to create your API endpoints, for example:

from rest_framework.views import APIView

class FCMDevicesListAPIView(APIView):

permission_classes = (IsAuthenticated, )

def get(self, request):
    queryset = CustomFCMDevice.objects.all()
    serializer = FCMDeviceSerializer(queryset, many=True)
    return Response(serializer.data)


问:
Replacing symbol strange situation
```<code>foreach($ret as $object)
{
    $res = $object->...;
    $img_src = $res[0]->src;
    echo $img_src . '<br />';
    echo str_replace("&size=2", "", $img_src) . '<br /><br />';
}
</code>```

$img_src ~ 'http://site.com/img.jpg&size=2'

And I have to receive same link but without &size=2. Why doesn't work my last line in code. It shows the same url.

答:
use preg_replace:

```<code>$c=preg_replace("/&size=2/","",$img_src);
</code>```

Example of usage

```<code><?php
$sr="http://site.com/img.jpg&size=2";
echo preg_replace("/&size=2/","",$sr);
?>
</code>```

This will output

```<code>http://site.com/img.jpg
</code>```

ContentLicense: CC BY-SA 3.0

Title: Replacing symbol strange situation

Body:
foreach($ret as $object)
{
    $res = $object->...;
    $img_src = $res[0]->src;
    echo $img_src . '
';
    echo str_replace("&size=2", "", $img_src) . '

';
}

$img_src ~ 'http://site.com/img.jpg&size=2'

And I have to receive same link but without &size=2. Why doesn't work my last line in code. It shows the same url.

Body:
use preg_replace:

$c=preg_replace("/&size=2/","",$img_src);

Example of usage

<?php
$sr="http://site.com/img.jpg&size=2";
echo preg_replace("/&size=2/","",$sr);
?>

This will output

http://site.com/img.jpg


问:
Javascript modified array before group by
i am trying to modified array before groupBy

i have this array

```<code>[
    {
        name: 'BoxOne',
        count: 3
    },
    {
        name: 'BoxTwo',
        count: 2
    },
]
</code>```

i am trying to modified as per count value has in object value count 3 + 2 = 5 object should in array

witch function i use ? for output array like this

```<code>[
    {
        name: 'BoxOne',
        count: 3
    },
    {
        name: 'BoxOne',
        count: 3
    },
    {
        name: 'BoxOne',
        count: 3
    },
    {
        name: 'BoxTwo',
        count: 2
    },
    {
        name: 'BoxTwo',
        count: 2
    },
]
</code>```

答:
You can iterate and flatten the before array with Array.flatMap(), and generate an array of items according to count using Array.from().

Note: You need to shallow clone the objects, if you don't want multiple references to the same object. This prevent all connected "objects" from changing, when one of them is changed.

const before = [{"name":"BoxOne","count":3},{"name":"BoxTwo","count":2}]

const after = before.flatMap(o =>
  Array.from({ length: o.count }, () => ({ ...o }))
)

console.log(after)```

Body:
i am trying to modified array before groupBy

i have this array

[
    {
        name: 'BoxOne',
        count: 3
    },
    {
        name: 'BoxTwo',
        count: 2
    },
]

i am trying to modified as per count value has in object value count 3 + 2 = 5 object should in array

witch function i use ? for output array like this

[
    {
        name: 'BoxOne',
        count: 3
    },
    {
        name: 'BoxOne',
        count: 3
    },
    {
        name: 'BoxOne',
        count: 3
    },
    {
        name: 'BoxTwo',
        count: 2
    },
    {
        name: 'BoxTwo',
        count: 2
    },
]


问:
.NET Entity Framework and stored procedures
I'm new to EF and I got a bit of a philosophical question: all the books, videos, online courses etc - go on and on about working directly with table databases - i.e. with classes that correspond directly to them. How the class I create will abstract away the tables and all that. and then the entire books or courses show all the things I can do to a class that will in turn happen at the database table - the CRUD operations and such.

And I'm thinking - we never work directly with tables, and there are reasons for it. Its such a bad idea - be for us to do it manually or for a framework to handle it for us. We always work with stored procedures, which is the way it should be done (they return SELECTs which JOINs from a bunch of tables typically, and this way we exploit the relational model and encapsulate it. we give permissions to execute stored procedures, not directly, full access to tables, etc etc...)

But all the EF material is 99% on OR mapping which is code-to-physical table, and then a quick mention that its possible to do it with stored procedures.

So... is that the thinking behind the EF philosophy? did I get it right and... what were MS people thinking??

Thank you

答:
There is more: EF is not bound or limited to SQL Server. It's an abstraction of the datalayer which has some benefits over the database approach.

Btw, you can call stored procedures in EF, but still, here some other benefits:

abstracting data access

having data tables, views etc well defined in code. This helps prevent mapping mistakes.

code first has very well defined migration strategies

and; it allows you to switch your actual database type. This is helpful when writing tests.

finally: it can save a lot of time and has not a really steep learning curve for people that know C#


问:
A specified Include path is not valid. The EntityType 'DB_A50B96_aljawdahlabModel.LAB_RESULTS'
I got this error when click details link , I want to make relation between tables by using .Include() and read the name of patient and test name and there is relation between the tables and Foreign Key
The error :

"A specified Include path is not valid.  The EntityType 'DB_A50B96_aljawdahlabModel.LAB_RESULTS'  does not declare a navigation property with the name 'patient_no'."

This is LAB_RESULTS Model :

```<code>using System;
    using System.Collections.Generic;
    using System.ComponentModel.DataAnnotations.Schema;

        public partial class LAB_RESULTS
        {
            public int ID { get; set; }
            public int SAMPLE_ID { get; set; }
            public int ORDER_ID { get; set; }
            public int TESTID { get; set; }
            public int GROUPID { get; set; }
            public string NORMAL_RESULT { get; set; }
            public int SAMPLE_STATUS { get; set; }
            public string EXAMINED_BY { get; set; }
            public Nullable<System.DateTime> EXAMINED_DATE { get; set; }
            public string APPROVED_BY { get; set; }
            public Nullable<System.DateTime> APPROVED_DATE { get; set; }
            public string RESULT_NUMBER { get; set; }
            public string RESULT_REPORT { get; set; }
            public string RESULT_NOTE { get; set; }
            public Nullable<int> packageid { get; set; }
            public Nullable<int> machine_id { get; set; }
            public Nullable<int> deptid { get; set; }

            [ForeignKey("patient_no")]
            public Nullable<int> patient_no { get; set; }
            public Nullable<int> custid { get; set; }
            public string REQ_FORM_NO { get; set; }
            public Nullable<int> serial { get; set; }
            public string text { get; set; }
            public string value { get; set; }
            public string packagename { get; set; }
            public string UPDATED_BY { get; set; }
            public Nullable<System.DateTime> UPDATED_DATE { get; set; }
            public Nullable<int> prio_id { get; set; }
            public Nullable<int> update_count { get; set; }
            public string REJECTED_BY { get; set; }
            public Nullable<System.DateTime> REJECTED_DATE { get; set; }
            public Nullable<int> REJECTED_REASON { get; set; }

          //  public int Patient_no { get; set; }
          //  public Patients Patients { get; set; }

           // public LabTests labtests { get; set; }
            public virtual LabTests LabTests { get; set; }
            public virtual Patients Patients { get; set; }
        }
    }
</code>```

This is patient class :

```<code>using System;
    using System.Collections.Generic;

    public partial class Patients
    {
        [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors")]
        public Patients()
        {
            this.LAB_PARA_RESULTS = new HashSet<LAB_PARA_RESULTS>();
            this.LAB_RESULTS = new HashSet<LAB_RESULTS>();
        }

        public int Patient_No { get; set; }
        public string Patient_Name { get; set; }
        public Nullable<int> Age { get; set; }
        public string Mobile { get; set; }
        public string Email { get; set; }
        public string Address { get; set; }
        public Nullable<int> Gender { get; set; }
        public string Patient_id { get; set; }
        public Nullable<int> Natid { get; set; }
        public byte[] insurance_card { get; set; }
        public byte[] ID_card { get; set; }
        public string patient_Name_Arabic { get; set; }
        public Nullable<int> catid { get; set; }
        public Nullable<System.DateTime> DateOfBirth { get; set; }
        public Nullable<System.DateTime> DateAdded { get; set; }
        public string AddedBy { get; set; }
        public string HijriBirthDate { get; set; }
        public string PCfileNo { get; set; }
        public string GregBirthDate { get; set; }

        [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
        public virtual ICollection<LAB_PARA_RESULTS> LAB_PARA_RESULTS { get; set; }
        [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
        public virtual ICollection<LAB_RESULTS> LAB_RESULTS { get; set; }
    }
}
</code>```

This is the controller :

```<code>public ActionResult CashData(int id)
        {
            var tables = new Orders_Tables
            {
                LabResults = db.LAB_RESULTS
                             .Include(p=>p.patient_no)
                             .Include(t=>t.TESTID)
                             .Where(o => o.ORDER_ID == id).ToList(),
                labtests = db.LabTests.ToList(),
                patients = db.Patients.ToList()
            };
            return View(tables);
        }
</code>```

This is the view :

```<code>@model AljawdahNewSite.Models.Orders_Tables
@{
    ViewBag.Title = "CashData";
    Layout = "~/Views/Shared/_LayoutPatients.cshtml";
}

<h2>CashData</h2>

<ul class="nav nav-tabs">
    <li class="nav-item">
        <a class="nav-link active" data-toggle="tab" href="#home">Laboratory Results</a>
    </li>
    <li class="nav-item">
        <a class="nav-link" data-toggle="tab" href="#menu1">Departments</a>
    </li>
    <li class="nav-item">
        <a class="nav-link" data-toggle="tab" href="#menu2">Incentives</a>
    </li>
</ul>
<div class="tab-content">
    <div class="tab-pane container active" id="home">
        <h3 class="text-center text-uppercase">List of Employee</h3>
        <table class="table table-bordered">
            <thead>
                <tr>
                    <th>@Html.DisplayNameFor(m => m.LabResults.FirstOrDefault().patient_no)</th>
                    <th>@Html.DisplayNameFor(m => m.LabResults.FirstOrDefault().NORMAL_RESULT)</th>
                    <th>@Html.DisplayNameFor(m => m.LabResults.FirstOrDefault().APPROVED_DATE)</th>
                    <th>@Html.DisplayNameFor(m => m.patients.FirstOrDefault().Patient_Name)</th>
                    <th>@Html.DisplayNameFor(m => m.labtests.FirstOrDefault().TestName)</th>

                </tr>
            </thead>
            @foreach (var employee in Model.LabResults)
            {
                <tr>
                    <td>@employee.patient_no</td>
                    <td>@employee.NORMAL_RESULT</td>
                    <td>@employee.APPROVED_DATE</td>
                    <td>@employee.Patients.Patient_Name</td>
                    <td>@employee.LabTests.TestName</td>

                </tr>
            }
        </table>
    </div>
    </div>
</code>```

I checked the solutions but its different case , I checked this link :

A specified Include path is not valid. The EntityType does not declare a navigation property with the name *

How to solve this error the error appeared in the controller ?

答:
Like mentioned in comment, you couldn't include properties, just entities, the result will be like :

```<code>LabResults = db.LAB_RESULTS
            .Where(o => o.ORDER_ID == id)
            .Include(p=>p.LabTests)
            .Include(t=>t.Patients)
            .ToList();
</code>```

Include documentation

Body:
I got this error when click details link , I want to make relation between tables by using .Include() and read the name of patient and test name and there is relation between the tables and Foreign Key
The error :

"A specified Include path is not valid.  The EntityType 'DB_A50B96_aljawdahlabModel.LAB_RESULTS'  does not declare a navigation property with the name 'patient_no'."

This is LAB_RESULTS Model :

using System;
    using System.Collections.Generic;
    using System.ComponentModel.DataAnnotations.Schema;

        public partial class LAB_RESULTS
        {
            public int ID { get; set; }
            public int SAMPLE_ID { get; set; }
            public int ORDER_ID { get; set; }
            public int TESTID { get; set; }
            public int GROUPID { get; set; }
            public string NORMAL_RESULT { get; set; }
            public int SAMPLE_STATUS { get; set; }
            public string EXAMINED_BY { get; set; }
            public Nullable<System.DateTime> EXAMINED_DATE { get; set; }
            public string APPROVED_BY { get; set; }
            public Nullable<System.DateTime> APPROVED_DATE { get; set; }
            public string RESULT_NUMBER { get; set; }
            public string RESULT_REPORT { get; set; }
            public string RESULT_NOTE { get; set; }
            public Nullable<int> packageid { get; set; }
            public Nullable<int> machine_id { get; set; }
            public Nullable<int> deptid { get; set; }

            [ForeignKey("patient_no")]
            public Nullable<int> patient_no { get; set; }
            public Nullable<int> custid { get; set; }
            public string REQ_FORM_NO { get; set; }
            public Nullable<int> serial { get; set; }
            public string text { get; set; }
            public string value { get; set; }
            public string packagename { get; set; }
            public string UPDATED_BY { get; set; }
            public Nullable<System.DateTime> UPDATED_DATE { get; set; }
            public Nullable<int> prio_id { get; set; }
            public Nullable<int> update_count { get; set; }
            public string REJECTED_BY { get; set; }
            public Nullable<System.DateTime> REJECTED_DATE { get; set; }
            public Nullable<int> REJECTED_REASON { get; set; }

          //  public int Patient_no { get; set; }
          //  public Patients Patients { get; set; }

           // public LabTests labtests { get; set; }
            public virtual LabTests LabTests { get; set; }
            public virtual Patients Patients { get; set; }
        }
    }

This is patient class :

using System;
    using System.Collections.Generic;

    public partial class Patients
    {
        [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2214:DoNotCallOverridableMethodsInConstructors")]
        public Patients()
        {
            this.LAB_PARA_RESULTS = new HashSet<LAB_PARA_RESULTS>();
            this.LAB_RESULTS = new HashSet<LAB_RESULTS>();
        }

        public int Patient_No { get; set; }
        public string Patient_Name { get; set; }
        public Nullable<int> Age { get; set; }
        public string Mobile { get; set; }
        public string Email { get; set; }
        public string Address { get; set; }
        public Nullable<int> Gender { get; set; }
        public string Patient_id { get; set; }
        public Nullable<int> Natid { get; set; }
        public byte[] insurance_card { get; set; }
        public byte[] ID_card { get; set; }
        public string patient_Name_Arabic { get; set; }
        public Nullable<int> catid { get; set; }
        public Nullable<System.DateTime> DateOfBirth { get; set; }
        public Nullable<System.DateTime> DateAdded { get; set; }
        public string AddedBy { get; set; }
        public string HijriBirthDate { get; set; }
        public string PCfileNo { get; set; }
        public string GregBirthDate { get; set; }

        [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
        public virtual ICollection<LAB_PARA_RESULTS> LAB_PARA_RESULTS { get; set; }
        [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")]
        public virtual ICollection<LAB_RESULTS> LAB_RESULTS { get; set; }
    }
}

This is the controller :

public ActionResult CashData(int id)
        {
            var tables = new Orders_Tables
            {
                LabResults = db.LAB_RESULTS
                             .Include(p=>p.patient_no)
                             .Include(t=>t.TESTID)
                             .Where(o => o.ORDER_ID == id).ToList(),
                labtests = db.LabTests.ToList(),
                patients = db.Patients.ToList()
            };
            return View(tables);
        }

This is the view :

@model AljawdahNewSite.Models.Orders_Tables
@{
    ViewBag.Title = "CashData";
    Layout = "~/Views/Shared/_LayoutPatients.cshtml";
}

CashData

        Laboratory Results

        Departments

        Incentives

List of Employee

                    @Html.DisplayNameFor(m => m.LabResults.FirstOrDefault().patient_no)
                    @Html.DisplayNameFor(m => m.LabResults.FirstOrDefault().NORMAL_RESULT)
                    @Html.DisplayNameFor(m => m.LabResults.FirstOrDefault().APPROVED_DATE)
                    @Html.DisplayNameFor(m => m.patients.FirstOrDefault().Patient_Name)
                    @Html.DisplayNameFor(m => m.labtests.FirstOrDefault().TestName)

            @foreach (var employee in Model.LabResults)
            {

                    @employee.patient_no
                    @employee.NORMAL_RESULT
                    @employee.APPROVED_DATE
                    @employee.Patients.Patient_Name
                    @employee.LabTests.TestName

            }

I checked the solutions but its different case , I checked this link :

A specified Include path is not valid. The EntityType does not declare a navigation property with the name *

How to solve this error the error appeared in the controller ?

Body:
Like mentioned in comment, you couldn't include properties, just entities, the result will be like :

LabResults = db.LAB_RESULTS
            .Where(o => o.ORDER_ID == id)
            .Include(p=>p.LabTests)
            .Include(t=>t.Patients)
            .ToList();

Include documentation


问:
SetBackgroundColor for even items in RecyclerView
I want to setBackgroundColor for even items in my RecyclerView. I tried something like that in theAdapter class:

```<code>  override fun onBindViewHolder(holder: ServersViewHolder, position: Int) {
        val server: Server = list[position]

        if (position % 2 == 0){
            holder.mConstraintLayout.setBackgroundColor(R.color.colorRed)
        }

        holder.bind(server)
    }
</code>```

But it doesn't work fine. Could you help me?

EDIT

```<code>class ServerLisAdapter: RecyclerView.Adapter<ServersViewHolder>() {

    private var list = emptyList<Server>()

    override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): ServersViewHolder {
        val view = LayoutInflater.from(parent.context).inflate(R.layout.item_server_list, parent, false)
        return ServersViewHolder(view)
    }

    override fun getItemCount(): Int {
        return list.size
    }

    override fun onBindViewHolder(holder: ServersViewHolder, position: Int) {
        val server: Server = list[position]

        if (position % 2 == 0){
            holder.mConstraintLayout.setBackgroundColor(R.color.colorRed)
        }

        holder.bind(server)
    }

    fun setList(serverList: List<Server>) {
        list = serverList
        notifyDataSetChanged()
    }
}
</code>```

答:
Recycler view reuses the viewholders so you should be setting colors for both even and odd items:

```<code>override fun onBindViewHolder(holder: ServersViewHolder, position: Int) {
    val server: Server = list[position]

    if (position % 2 == 0){
        holder.mConstraintLayout.setBackgroundColor(R.color.colorRed)
    } else {
        holder.mConstraintLayout.setBackgroundColor(R.color.normalColor)  // replace normalColor with your default color.
    }

    holder.bind(server)
}
</code>```

This will make the background color correct even if the view holder is reused.

Body:
I want to setBackgroundColor for even items in my RecyclerView. I tried something like that in theAdapter class:

  override fun onBindViewHolder(holder: ServersViewHolder, position: Int) {
        val server: Server = list[position]

        if (position % 2 == 0){
            holder.mConstraintLayout.setBackgroundColor(R.color.colorRed)
        }

        holder.bind(server)
    }

But it doesn't work fine. Could you help me?

EDIT

class ServerLisAdapter: RecyclerView.Adapter<ServersViewHolder>() {

    private var list = emptyList<Server>()

    override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): ServersViewHolder {
        val view = LayoutInflater.from(parent.context).inflate(R.layout.item_server_list, parent, false)
        return ServersViewHolder(view)
    }

    override fun getItemCount(): Int {
        return list.size
    }

    override fun onBindViewHolder(holder: ServersViewHolder, position: Int) {
        val server: Server = list[position]

        if (position % 2 == 0){
            holder.mConstraintLayout.setBackgroundColor(R.color.colorRed)
        }

        holder.bind(server)
    }

    fun setList(serverList: List<Server>) {
        list = serverList
        notifyDataSetChanged()
    }
}

Body:
Recycler view reuses the viewholders so you should be setting colors for both even and odd items:

override fun onBindViewHolder(holder: ServersViewHolder, position: Int) {
    val server: Server = list[position]

    if (position % 2 == 0){
        holder.mConstraintLayout.setBackgroundColor(R.color.colorRed)
    } else {
        holder.mConstraintLayout.setBackgroundColor(R.color.normalColor)  // replace normalColor with your default color.
    }

    holder.bind(server)
}

This will make the background color correct even if the view holder is reused.


问:
execSQL(); method not working properly. how can i make it work?
I am trying to create a new table but as soon as i run the app it shows me an error that something is not right in the db.execSQL();</p>

```<code>public void onCreate(SQLiteDatabase db) {
    db.execSQL("CREATE TABLE "+TABLE_NAME+"(ID INTEGER PRIMARY KEY AUTOINCREMENT, Username TEXT, Password TEXT");
}
</code>```

答:
Update your code :

```<code>public void onCreate(SQLiteDatabase db) {
    db.execSQL("CREATE TABLE "+TABLE_NAME+"(ID INTEGER PRIMARY KEY AUTOINCREMENT, Username TEXT, Password TEXT)”);
</code>```

}

There is an issue in SQL query statement, I hope it helps you. Thanks

Body:
I am trying to create a new table but as soon as i run the app it shows me an error that something is not right in the db.execSQL();

public void onCreate(SQLiteDatabase db) {
    db.execSQL("CREATE TABLE "+TABLE_NAME+"(ID INTEGER PRIMARY KEY AUTOINCREMENT, Username TEXT, Password TEXT");
}

Body:
Update your code :

public void onCreate(SQLiteDatabase db) {
    db.execSQL("CREATE TABLE "+TABLE_NAME+"(ID INTEGER PRIMARY KEY AUTOINCREMENT, Username TEXT, Password TEXT)”);

}

There is an issue in SQL query statement, I hope it helps you. Thanks


问:
How do I change default font of Summernote in Django?
So I'm using django-summernote (I'm using Django ver 3.x), and trying to change the default font in the editor. Here's my code.

(part of) forms.py:

```<code>from .models import MyModel

class MyInputForm(forms.ModelForm):
    contents = SummernoteTextFormField()

        class Meta:
        model=MyModel
        fields=['contents']
        widgets = {
        'contents': SummernoteInplaceWidget()
        }
</code>```

(part of) my template :

```<code><form method="post" class="form-group">
  {% csrf_token %}
  <div class="row">
    <div class="col col-8">
      {{form.contents|as_crispy_field}}
    </div>
  </div>
</form>
</code>```

And in case you need to take a look, (part of) my settings.py

```<code>SUMMERNOTE_CONFIG = {
    'iframe': True,
    'lang' : 'ko-KR',
    'summernote': {
        'width': '100%',
        'height': '400px',
        'toolbar': [
            ['style', ['style',]],
            ['font', ['fontname', 'fontsize', 'bold', 'italic', 'strikethrough', 'clear',]],
            ['color', ['forecolor', 'backcolor', ]],
            ['para', ['ul', 'ol', 'height']],
            ['insert', ['link']],
            ['misc', ['picture', 'fullscreen', 'codeview', 'print', 'help', ]],
        ],
    },
    'js': (
        '/static/summernote-ext-print.js',
    ),
    'js_for_inplace': (
        '/static/summernote-ext-print.js',
    ),
    'css': (
        '//cdnjs.cloudflare.com/ajax/libs/codemirror/5.40.0/theme/base16-dark.min.css',
    ),
    'css_for_inplace': (
        '//cdnjs.cloudflare.com/ajax/libs/codemirror/5.40.0/theme/base16-dark.min.css',
    ),
    'codemirror': {
        'theme': 'base16-dark',
        'mode': 'htmlmixed',
        'lineNumbers': 'true',
    },
    'lazy': False,
}

SUMMERNOTE_THEME = 'bs4'
X_FRAME_OPTIONS = 'SAMEORIGIN'
</code>```

I have no idea on how or where to write my code for changing the default font.

I would really appreciate your help. Thanks. :)

答: You shouldn't worry about that. Copy and paste text in any format in the editor, summernote will accept and adjust.</p>

Body:
So I'm using django-summernote (I'm using Django ver 3.x), and trying to change the default font in the editor. Here's my code.

(part of) forms.py:

from .models import MyModel

class MyInputForm(forms.ModelForm):
    contents = SummernoteTextFormField()

        class Meta:
        model=MyModel
        fields=['contents']
        widgets = {
        'contents': SummernoteInplaceWidget()
        }

(part of) my template :

<form method="post" class="form-group">
  {% csrf_token %}

      {{form.contents|as_crispy_field}}

</form>

And in case you need to take a look, (part of) my settings.py

SUMMERNOTE_CONFIG = {
    'iframe': True,
    'lang' : 'ko-KR',
    'summernote': {
        'width': '100%',
        'height': '400px',
        'toolbar': [
            ['style', ['style',]],
            ['font', ['fontname', 'fontsize', 'bold', 'italic', 'strikethrough', 'clear',]],
            ['color', ['forecolor', 'backcolor', ]],
            ['para', ['ul', 'ol', 'height']],
            ['insert', ['link']],
            ['misc', ['picture', 'fullscreen', 'codeview', 'print', 'help', ]],
        ],
    },
    'js': (
        '/static/summernote-ext-print.js',
    ),
    'js_for_inplace': (
        '/static/summernote-ext-print.js',
    ),
    'css': (
        '//cdnjs.cloudflare.com/ajax/libs/codemirror/5.40.0/theme/base16-dark.min.css',
    ),
    'css_for_inplace': (
        '//cdnjs.cloudflare.com/ajax/libs/codemirror/5.40.0/theme/base16-dark.min.css',
    ),
    'codemirror': {
        'theme': 'base16-dark',
        'mode': 'htmlmixed',
        'lineNumbers': 'true',
    },
    'lazy': False,
}

SUMMERNOTE_THEME = 'bs4'
X_FRAME_OPTIONS = 'SAMEORIGIN'

I have no idea on how or where to write my code for changing the default font.

I would really appreciate your help. Thanks. :)


问:
Different output on changing the position of fgets() function
The output is correct when fgets() in included in the while loop, but taking it outside makes it an infinite loop. Can anyone explain why?</p>

```<code>main()
{
    FILE *fp=fopen("myfile.txt","r");
    char s[100];
    fgets(s,50,fp);
    while(s!=NULL) //infinte loop
        puts(s);
    /* while((fgets(s,100,fp))!=NULL)
          puts(s);
       This runs fine */
    fclose(fp);
}
</code>```

答:
s!=NULL compares the address of the array s against NULL, which will never match.

while(fgets(s,100,fp))!=NULL) compares the return of fgets() with NULL, which is NULL on EOF or error.

Search for:

```man page fgets```

Body:
The output is correct when fgets() in included in the while loop, but taking it outside makes it an infinite loop. Can anyone explain why?

main()
{
    FILE *fp=fopen("myfile.txt","r");
    char s[100];
    fgets(s,50,fp);
    while(s!=NULL) //infinte loop
        puts(s);
    /* while((fgets(s,100,fp))!=NULL)
          puts(s);
       This runs fine */
    fclose(fp);
}

Body:
s!=NULL compares the address of the array s against NULL, which will never match.

while(fgets(s,100,fp))!=NULL) compares the return of fgets() with NULL, which is NULL on EOF or error.

Search for:

man page fgets


问:
Android : how to pass a integer value to service using KSOAP in android
Not able to pass an integer value to the service request.The value that reaches service request becomes null
Here is my code

```<code>private static final String METHOD_NAME ="GetPrivileges";
private static final String NAMESPACE = "http://AuthorizationManagement.ServiceContracts/2007/01/";
private static final String URL ="http://192.168.5.219/NTLS_Authorization
</code>```

/AuthorisationManager.asmx";

```<code>final String SOAP_ACTION ="http://AuthorizationManagement.ServiceContracts/2007/01/GetPrivileges";
    public void call() {
        try {
            SoapObject request = new SoapObject(NAMESPACE, METHOD_NAME);

            PropertyInfo pi=new PropertyInfo();
            pi.type=PropertyInfo.INTEGER_CLASS;
            pi.setName("RoleID");
            pi.setValue(3);
            pi.setNamespace(NAMESPACE);
            request.addProperty(pi);

            SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER11);
            envelope.dotNet = true;
            envelope.setOutputSoapObject(request);

            HttpTransportSE androidHttpTransport = new HttpTransportSE(URL);
            androidHttpTransport.call(SOAP_ACTION, envelope);

            Object result = envelope.getResponse();

            String resultData = result.toString();
</code>```

答:
simply you can add this

```<code>requestObject.addProperty("RoleID",3);
</code>```

May be try this code  //note don't put directly number(3 in ur case) instead pass it as parameter ...

```<code>    final SoapObject requestObject = new SoapObject(Constants.NAMESPACE,METHOD_NAME );
            SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER11);
            envelope.dotNet = false;
            requestObject.addProperty("RoleID",number);

            envelope.setOutputSoapObject(requestObject);
            AndroidHttpTransport androidHttpTransport =new AndroidHttpTransport(Constants.URL);
            try
            {
                androidHttpTransport.call(Constants.SOAP_ACTION+METHOD_NAME, envelope);
                SoapObject response = (SoapObject)envelope.getResponse();
                Log.v("result",response.toString());
}
 catch(Exception e)
        {
            e.printStackTrace();

        }
</code>```

Body:
Not able to pass an integer value to the service request.The value that reaches service request becomes null
Here is my code

private static final String METHOD_NAME ="GetPrivileges";
private static final String NAMESPACE = "http://AuthorizationManagement.ServiceContracts/2007/01/";
private static final String URL ="http://192.168.5.219/NTLS_Authorization

/AuthorisationManager.asmx";

final String SOAP_ACTION ="http://AuthorizationManagement.ServiceContracts/2007/01/GetPrivileges";
    public void call() {
        try {
            SoapObject request = new SoapObject(NAMESPACE, METHOD_NAME);

            PropertyInfo pi=new PropertyInfo();
            pi.type=PropertyInfo.INTEGER_CLASS;
            pi.setName("RoleID");
            pi.setValue(3);
            pi.setNamespace(NAMESPACE);
            request.addProperty(pi);

            SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER11);
            envelope.dotNet = true;
            envelope.setOutputSoapObject(request);

            HttpTransportSE androidHttpTransport = new HttpTransportSE(URL);
            androidHttpTransport.call(SOAP_ACTION, envelope);

            Object result = envelope.getResponse();

            String resultData = result.toString();

Body:
simply you can add this

requestObject.addProperty("RoleID",3);

May be try this code  //note don't put directly number(3 in ur case) instead pass it as parameter ...

    final SoapObject requestObject = new SoapObject(Constants.NAMESPACE,METHOD_NAME );
            SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER11);
            envelope.dotNet = false;
            requestObject.addProperty("RoleID",number);

            envelope.setOutputSoapObject(requestObject);
            AndroidHttpTransport androidHttpTransport =new AndroidHttpTransport(Constants.URL);
            try
            {
                androidHttpTransport.call(Constants.SOAP_ACTION+METHOD_NAME, envelope);
                SoapObject response = (SoapObject)envelope.getResponse();
                Log.v("result",response.toString());
}
 catch(Exception e)
        {
            e.printStackTrace();

        }