Automatic calculation of line orientations in QGIS





.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{
margin-bottom:0;
}








2















I was able to see the types of cables ("* TYPE " in my data table) entered manually and the length of these cables (automatically calculated using the " Slength *" function with the name LONG in the field calculator). this whole info on the same label



("*TYPE||'n'||LONG||'m'*").


enter image description here



It is now impossible to make visible the orientation of the cables (Shape of line type) in gradians (between 0 and 400), with the origin reference in the Eastern direction.










share|improve this question

































    2















    I was able to see the types of cables ("* TYPE " in my data table) entered manually and the length of these cables (automatically calculated using the " Slength *" function with the name LONG in the field calculator). this whole info on the same label



    ("*TYPE||'n'||LONG||'m'*").


    enter image description here



    It is now impossible to make visible the orientation of the cables (Shape of line type) in gradians (between 0 and 400), with the origin reference in the Eastern direction.










    share|improve this question





























      2












      2








      2


      2






      I was able to see the types of cables ("* TYPE " in my data table) entered manually and the length of these cables (automatically calculated using the " Slength *" function with the name LONG in the field calculator). this whole info on the same label



      ("*TYPE||'n'||LONG||'m'*").


      enter image description here



      It is now impossible to make visible the orientation of the cables (Shape of line type) in gradians (between 0 and 400), with the origin reference in the Eastern direction.










      share|improve this question
















      I was able to see the types of cables ("* TYPE " in my data table) entered manually and the length of these cables (automatically calculated using the " Slength *" function with the name LONG in the field calculator). this whole info on the same label



      ("*TYPE||'n'||LONG||'m'*").


      enter image description here



      It is now impossible to make visible the orientation of the cables (Shape of line type) in gradians (between 0 and 400), with the origin reference in the Eastern direction.







      qgis






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited May 27 at 12:44









      Mat

      1,1311 gold badge6 silver badges17 bronze badges




      1,1311 gold badge6 silver badges17 bronze badges










      asked May 27 at 10:24









      Gil MirandaGil Miranda

      133 bronze badges




      133 bronze badges

























          1 Answer
          1






          active

          oldest

          votes


















          5
















          To get line angle you can use field calculator depending what exactly you need:
          - line_interpolate_angle(geometry,distance)
          - angle_at_vertex(geometry,vertex)



          For more details check help in field calculator: enter image description here



          Result is in degrees (north origin), to convert it in grads you need to multiply by (400/360).
          So field calculator expression would be something like: line_interpolate_angle($geometry,0) * (400 / 360).



          Since you need angle originating from east you will need to add 90°: (line_interpolate_angle($geometry,0)+90 )* (400 / 360) and substract 400 for features that have value above 400g.






          share|improve this answer




























          • I'll have to do some ajusts but it was really helpfull. Thx

            – Gil Miranda
            May 27 at 12:57













          Your Answer








          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "79"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: false,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/4.0/"u003ecc by-sa 4.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });















          draft saved

          draft discarded
















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fgis.stackexchange.com%2fquestions%2f324024%2fautomatic-calculation-of-line-orientations-in-qgis%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          5
















          To get line angle you can use field calculator depending what exactly you need:
          - line_interpolate_angle(geometry,distance)
          - angle_at_vertex(geometry,vertex)



          For more details check help in field calculator: enter image description here



          Result is in degrees (north origin), to convert it in grads you need to multiply by (400/360).
          So field calculator expression would be something like: line_interpolate_angle($geometry,0) * (400 / 360).



          Since you need angle originating from east you will need to add 90°: (line_interpolate_angle($geometry,0)+90 )* (400 / 360) and substract 400 for features that have value above 400g.






          share|improve this answer




























          • I'll have to do some ajusts but it was really helpfull. Thx

            – Gil Miranda
            May 27 at 12:57
















          5
















          To get line angle you can use field calculator depending what exactly you need:
          - line_interpolate_angle(geometry,distance)
          - angle_at_vertex(geometry,vertex)



          For more details check help in field calculator: enter image description here



          Result is in degrees (north origin), to convert it in grads you need to multiply by (400/360).
          So field calculator expression would be something like: line_interpolate_angle($geometry,0) * (400 / 360).



          Since you need angle originating from east you will need to add 90°: (line_interpolate_angle($geometry,0)+90 )* (400 / 360) and substract 400 for features that have value above 400g.






          share|improve this answer




























          • I'll have to do some ajusts but it was really helpfull. Thx

            – Gil Miranda
            May 27 at 12:57














          5














          5










          5









          To get line angle you can use field calculator depending what exactly you need:
          - line_interpolate_angle(geometry,distance)
          - angle_at_vertex(geometry,vertex)



          For more details check help in field calculator: enter image description here



          Result is in degrees (north origin), to convert it in grads you need to multiply by (400/360).
          So field calculator expression would be something like: line_interpolate_angle($geometry,0) * (400 / 360).



          Since you need angle originating from east you will need to add 90°: (line_interpolate_angle($geometry,0)+90 )* (400 / 360) and substract 400 for features that have value above 400g.






          share|improve this answer















          To get line angle you can use field calculator depending what exactly you need:
          - line_interpolate_angle(geometry,distance)
          - angle_at_vertex(geometry,vertex)



          For more details check help in field calculator: enter image description here



          Result is in degrees (north origin), to convert it in grads you need to multiply by (400/360).
          So field calculator expression would be something like: line_interpolate_angle($geometry,0) * (400 / 360).



          Since you need angle originating from east you will need to add 90°: (line_interpolate_angle($geometry,0)+90 )* (400 / 360) and substract 400 for features that have value above 400g.







          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited May 27 at 11:27

























          answered May 27 at 11:19









          MatMat

          1,1311 gold badge6 silver badges17 bronze badges




          1,1311 gold badge6 silver badges17 bronze badges
















          • I'll have to do some ajusts but it was really helpfull. Thx

            – Gil Miranda
            May 27 at 12:57



















          • I'll have to do some ajusts but it was really helpfull. Thx

            – Gil Miranda
            May 27 at 12:57

















          I'll have to do some ajusts but it was really helpfull. Thx

          – Gil Miranda
          May 27 at 12:57





          I'll have to do some ajusts but it was really helpfull. Thx

          – Gil Miranda
          May 27 at 12:57



















          draft saved

          draft discarded



















































          Thanks for contributing an answer to Geographic Information Systems Stack Exchange!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fgis.stackexchange.com%2fquestions%2f324024%2fautomatic-calculation-of-line-orientations-in-qgis%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          He _____ here since 1970 . Answer needed [closed]What does “since he was so high” mean?Meaning of “catch birds for”?How do I ensure “since” takes the meaning I want?“Who cares here” meaningWhat does “right round toward” mean?the time tense (had now been detected)What does the phrase “ring around the roses” mean here?Correct usage of “visited upon”Meaning of “foiled rail sabotage bid”It was the third time I had gone to Rome or It is the third time I had been to Rome

          Bunad

          Færeyskur hestur Heimild | Tengill | Tilvísanir | LeiðsagnarvalRossið - síða um færeyska hrossið á færeyskuGott ár hjá færeyska hestinum